Comments (3)
@elethiame
Can you describe in detail the steps to reproduce?
from plugins.
const RunningPage({Key? key}) : super(key: key);
@override
_RunningPageState createState() => _RunningPageState();
}
class _RunningPageState extends State<RunningPage> {
late VideoPlayerController _controller;
late final AppLifecycleListener _appLifecycleListener;
@override
void initState() {
super.initState();
_controller = VideoPlayerController.asset('assets/videos/config_video.mp4')
..initialize().then((_) {
_controller.setLooping(true);
_controller.play();
});
_appLifecycleListener = AppLifecycleListener(
onStateChange: (state) async {
if (state == AppLifecycleState.resumed) {
UILogger.info('app resumed, play video');
_controller.play();
} else if (state == AppLifecycleState.paused) {
UILogger.info('app paused, pause video');
_controller.pause();
}
},
);
}
@override
void dispose() {
_controller.dispose();
_appLifecycleListener.dispose();
super.dispose();
}
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.black,
body: Stack(
fit: StackFit.expand,
alignment: Alignment.center,
children: [
AspectRatio(
aspectRatio: _controller.value.aspectRatio,
child: VideoPlayer(_controller),
),
Focus(
autofocus: true,
onKey: (node, event) {
if (event is RawKeyDownEvent) {}
if (event.isConfirmKeyPressed() || event.isEscapeKeyPressed()) {
_stop(context);
return KeyEventResult.handled;
}
return KeyEventResult.ignored;
},
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
mainAxisSize: MainAxisSize.min,
children: [
Text(
context.localizations.runningPageSubtitle,
style: TextStyle(
fontSize: 24.px,
fontWeight: FontWeight.w500,
color: Color(0x99FFFFFF),
),
),
SizedBox(
height: 20.px,
),
_buildRichText(),
],
),
),
_buildCapturePosition(),
],
),
);
}
}
When this page is loaded, an error is thrown, but everything else seems alright:
[E] [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: PlatformException(Pause, Player pause failed, null, null)
#0 VideoPlayerAvplayApi.pause (package:video_player_avplay/src/messages.g.dart:803:7)
https://github.com/flutter-tizen/plugins/pull/1 VideoPlayerController._applyPlayPause (package:video_player_avplay/video_player.dart:615:7)
https://github.com/flutter-tizen/plugins/pull/2 VideoPlayerController.pause (package:video_player_avplay/video_player.dart:543:5)
Then, I return to the TV home screen and open Bilibili to play a video. After that, when I go back to my app, the video widget appears black.
I am using this package on Samsung TV Q60C/Q70C for China.
from plugins.
Hi, in China current TV products are different from global TV, both android app and tizen app can run on Chinese products, if you develop tizen app, you need to send request to us for app entry(your app will be shown in "ζηεΊη¨") when release.
from plugins.
Related Issues (20)
- [video_player_avplay] There are GStreamer errors in the log HOT 4
- [tizen_bundle] Bundle creation issue HOT 2
- [ci] The release workflow fails HOT 1
- Ongoing Activity HOT 5
- [webview_flutter_tizen] crash when run on real TV device HOT 34
- Not supporting low latency mode (HLS) HOT 2
- Inconsistent statements in documentation HOT 2
- [video_player_avplay] The type of plusplayer's volume is different
- [video_player_avplay] Failed to build video_player_avplay plugin HOT 2
- Unresolved reference: samsung kotlin(UNRESOLVED_REFERENCE)
- [wearable_rotary] First RotaryController of NavigationStack never dismissed HOT 2
- [video_player_avplay] Unable to build for 8.0 Tizen Version HOT 10
- CI build error HOT 1
- [google_maps_flutter] Cannot resolve package dependencies HOT 1
- [google_maps_flutter] GoogleMaps isn't work when using 3.57 version or higher. HOT 1
- [webview_flutter_tizen] Crash occurs when creating webview again HOT 2
- video_player_avplay crash HOT 2
- Update tizen_interop to 0.3.0 HOT 3
- [google_maps_flutter] InfoWindow is displayed incorrectly HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from plugins.