We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
debug 模式一下一切正常 但是 release 模式下手,video 播放就白屏,但是声音正常播放 已关闭混淆 请帮忙看看是什么问题导致的呢 Adroid 系统版本:Android 10 Flutter 相关版本:
Flutter: 2.10.5 Dart: 2.16.2 fijkplayer: 0.11.0
android\app\build.gradle :
buildTypes { release { signingConfig signingConfigs.debug minifyEnabled false shrinkResources false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } }
android\app\proguard-rules.pro:
-keep class tv.danmaku.ijk.media.player.**{*;}
player 使用逻辑:
initPlayer() async { //初始化player player = FijkPlayer(); player.setDataSource('https://media.w3.org/2010/05/sintel/trailer_hd.mp4', autoPlay: true); player.addListener(_videoListener); } _videoListener() async { if(player != null) { if(player.state != playerState) { //状态发生改变 update(); playerState = player.state; } if(playerState == FijkState.completed) { // bubbleController.isShowWelcome.value = false; // 项目相关逻辑 } } }
The text was updated successfully, but these errors were encountered:
【问题解决了】 抱歉,不是 FijkView 插件本身的问题 Stack 和 Expanded 嵌套导致的异常 (debug 模式正常,release 异常) 取消了对 FijkView 父级 Expanded 的使用
@override Widget build(BuildContext context) { return GetBuilder(builder: (VideoLogic controller) { if(controller.player == null) return Container(); // return Expanded( return Container( alignment: Alignment.center, color: const Color(0xff111826), child: FijkView( player: controller.player, color: const Color(0xff111826), fit: FijkFit.cover, ), // ), ); }); }
Sorry, something went wrong.
No branches or pull requests
debug 模式一下一切正常
但是 release 模式下手,video 播放就白屏,但是声音正常播放
已关闭混淆
请帮忙看看是什么问题导致的呢
Adroid 系统版本:Android 10
Flutter 相关版本:
android\app\build.gradle :
android\app\proguard-rules.pro:
player 使用逻辑:
The text was updated successfully, but these errors were encountered: