Skip to content

[video_player] Platform view support #8810

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

FirentisTFW
Copy link
Contributor

@FirentisTFW FirentisTFW commented Mar 6, 2025

This PR adds support for platform views as on optional way of displaying a video (as an alternative to Flutter's Texture widget). Texture-based approach is still the default setting when creating a new player.

Platform interface was updated in #8453
Platform implementations were added in these PRs:

Closes flutter/issues/86613.

Pre-launch Checklist

@nateshmbhat

This comment was marked as off-topic.

@FirentisTFW
Copy link
Contributor Author

@nateshmbhat Looks like there's an issue with displaying SurfaceViews in Android (see #164899). We'll have to either wait for it to get fixed, try to find a workaround for it first or maybe just release this feature for iOS for now. I'm afraid there's no clear timeline for it yet, but I'll update you once I know more about this.

@nateshmbhat
Copy link

@nateshmbhat Looks like there's an issue with displaying SurfaceViews in Android (see #164899). We'll have to either wait for it to get fixed, try to find a workaround for it first or maybe just release this feature for iOS for now. I'm afraid there's no clear timeline for it yet, but I'll update you once I know more about this.

@FirentisTFW since most of the performance issues and crashes that we're hearing are more predominant in ios, i think its worth releasing this now for just ios 🙏🏻
Please consider this 🙏🏻

@RobertOdrowaz RobertOdrowaz force-pushed the feature/video-player-platform-view-support-app-facing branch from 1e6999f to e3b6f2e Compare May 20, 2025 11:46
@RobertOdrowaz RobertOdrowaz force-pushed the feature/video-player-platform-view-support-app-facing branch 3 times, most recently from 1321235 to 7c17709 Compare May 23, 2025 07:46
* Updates README to indicate that Andoid SDK <21 is no longer supported.
* Updates minimum supported SDK version to Flutter 3.24/Dart 3.5.
* Updates minimum supported SDK version to Flutter 3.27/Dart 3.6.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The latest version of video_player_android requires such constraints

@RobertOdrowaz RobertOdrowaz force-pushed the feature/video-player-platform-view-support-app-facing branch from 7c17709 to e6cb46d Compare May 23, 2025 08:35
@RobertOdrowaz RobertOdrowaz marked this pull request as ready for review May 23, 2025 09:49
@RobertOdrowaz RobertOdrowaz requested a review from tarrinneal as a code owner May 23, 2025 09:49
@RobertOdrowaz RobertOdrowaz force-pushed the feature/video-player-platform-view-support-app-facing branch from a1d2299 to 4de56f1 Compare May 26, 2025 05:22
@nateshmbhat

This comment was marked as off-topic.

@stuartmorgan-g

This comment was marked as off-topic.

@RobertOdrowaz RobertOdrowaz force-pushed the feature/video-player-platform-view-support-app-facing branch from a0eb439 to f513be0 Compare June 3, 2025 07:26
Copy link
Contributor

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@stuartmorgan-g stuartmorgan-g added the autosubmit Merge PR when tree becomes green via auto submit App label Jun 3, 2025
@auto-submit auto-submit bot merged commit 1765c95 into flutter:main Jun 3, 2025
80 checks passed
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Jun 3, 2025
github-merge-queue bot pushed a commit to flutter/flutter that referenced this pull request Jun 3, 2025
flutter/packages@4463066...1765c95

2025-06-03 [email protected] [video_player] Platform view
support (flutter/packages#8810)
2025-06-02 [email protected] [in_app_purchase_storekit] Add
support to win back offers / promotional offers (flutter/packages#8474)
2025-06-02 [email protected] [two_dimensional_scrollables]
Enable multi-cell/single-cell text selection in Simple Table example
(flutter/packages#8189)
2025-05-30 [email protected] [all_packages]
Bump `compileSdk` version to 35 (flutter/packages#9168)
2025-05-30 [email protected] Roll Flutter (stable) from
be698c4 to b25305a (11 revisions) (flutter/packages#9342)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected] on the revert to ensure that a
human
is aware of the problem.

To file a bug in Flutter:
https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://issues.skia.org/issues/new?component=1389291&template=1850622

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
autosubmit Merge PR when tree becomes green via auto submit App p: video_player
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[video_player] Feature request: Switch to PlatformView on iOS (and macOS when possible) to fix performance issues
4 participants