@@ -605,7 +605,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
|
||||
fallbackInProgress = false
|
||||
|
||||
// Configure basic MPV properties for Plex playback
|
||||
mpvCore?.setProperty("hwdec", "auto")
|
||||
mpvCore?.setProperty("hwdec", "mediacodec,mediacodec-copy")
|
||||
mpvCore?.setProperty("vo", "gpu")
|
||||
mpvCore?.setProperty("ao", "audiotrack")
|
||||
|
||||
|
||||
@@ -322,6 +322,9 @@ class MpvPlayerCore(private val activity: Activity) :
|
||||
MPVLib.setOptionString("opengl-es", "yes")
|
||||
// hwdec is set from Flutter via setProperty based on user preference
|
||||
|
||||
// Prevent crashes/artifacts from hardware film grain synthesis (mpv #14651)
|
||||
MPVLib.setOptionString("vd-lavc-film-grain", "cpu")
|
||||
|
||||
// Audio configuration
|
||||
MPVLib.setOptionString("ao", "audiotrack")
|
||||
}
|
||||
|
||||
@@ -2927,7 +2927,7 @@ String _getHwdecValue(bool enabled) {
|
||||
if (Platform.isMacOS || Platform.isIOS) {
|
||||
return 'videotoolbox';
|
||||
} else if (Platform.isAndroid) {
|
||||
return 'auto-safe';
|
||||
return 'mediacodec,mediacodec-copy';
|
||||
} else {
|
||||
return 'auto'; // Windows, Linux
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user