feat: Add native video player screen using media_kit for IPTV playback with extensive performance and audio optimizations.

This commit is contained in:
Michael committed 2025-12-21 18:05:29 +01:00
1 parent 915f75661f
commit d79d130126
4 files changed
+341 -567

No files matched your search

+2
View File
@@ -51,6 +51,8 @@ Structure toujours ta réponse ainsi :
- Commentaires explicatifs *dans* le code pour les parties complexes.
4. **Sécurité & Limitations :** Une note sur ce qui doit être configuré pour sécuriser ce code (ex: CORS, Rate Limiting).
---
**EXEMPLE D'INTERACTION :**
File diff suppressed because it is too large. Load diff
@@ -196,15 +196,15 @@ class _NativePlayerScreenState extends ConsumerState<NativePlayerScreen>
(_player.platform as dynamic)
?.setProperty('http-header-fields', 'User-Agent: XtremFlow/1.0');
// Live Stream optimizations - aggressive reconnection
// Live Stream optimizations - reconnection only
(_player.platform as dynamic)?.setProperty(
'stream-lavf-o',
'reconnect=1,reconnect_streamed=1,reconnect_on_network_error=1,reconnect_delay_max=10,reconnect_on_http_error=4xx,5xx',
'reconnect=1,reconnect_streamed=1,reconnect_on_network_error=1,reconnect_delay_max=5',
);
(_player.platform as dynamic)?.setProperty('force-seekable', 'yes');
// Removed: force-seekable and live_start_index=-1 which caused rollbacks
(_player.platform as dynamic)?.setProperty(
'demuxer-lavf-o',
'live_start_index=-1,analyzeduration=10000000,probesize=5000000',
'analyzeduration=5000000,probesize=2000000',
);
// Optimized for performance and stability on progressive & interlaced streams
@@ -384,6 +384,15 @@ class _NativePlayerScreenState extends ConsumerState<NativePlayerScreen>
super.deactivate();
}
@override
void didChangeAppLifecycleState(AppLifecycleState state) {
if (state == AppLifecycleState.paused ||
state == AppLifecycleState.inactive ||
state == AppLifecycleState.detached) {
_player.pause();
}
}
@override
void dispose() {
// Remove lifecycle observer
+1 -1
View File
@@ -1,7 +1,7 @@
name: xtremflow
description: High-performance IPTV Web Application with Xtream Codes API
publish_to: 'none'
version: 1.3.9+4
version: 1.5.0+10
environment:
sdk: '>=3.0.0 <4.0.0'