diff --git a/src/stremio_app/stremio_player/communication.rs b/src/stremio_app/stremio_player/communication.rs index 2378f47..e6d68e5 100644 --- a/src/stremio_app/stremio_player/communication.rs +++ b/src/stremio_app/stremio_player/communication.rs @@ -185,7 +185,7 @@ pub enum StrProp { SubColor, TrackList, VideoParams, - // Vo, + Vo, } stringable!(StrProp); diff --git a/src/stremio_app/stremio_player/player.rs b/src/stremio_app/stremio_player/player.rs index 83f89fb..06501b5 100644 --- a/src/stremio_app/stremio_player/player.rs +++ b/src/stremio_app/stremio_player/player.rs @@ -76,6 +76,7 @@ fn create_shareable_mpv(window_handle: HWND) -> Arc { set_property!("msg-level", "all=no"); set_property!("quiet", "yes"); set_property!("hwdec", "auto"); + // set_property!("vo", "gpu-next,"); Ok(()) }); Arc::new(mpv.expect("cannot build MPV")) @@ -228,6 +229,16 @@ fn create_message_thread( set_property(name, value, &mpv); } InMsg(InMsgFn::MpvSetProp, InMsgArgs::StProp(name, PropVal::Str(value))) => { + let value = if name.to_string() == "vo" { + let mut value = value; + if !value.is_empty() && !value.ends_with(',') { + value.push(','); + } + value.push_str("gpu-next,"); + value + } else { + value + }; set_property(name, value, &mpv); } InMsg(InMsgFn::MpvCommand, InMsgArgs::Cmd(cmd)) => {