@@ -625,7 +625,11 @@ void cMpvPlayer::PlayerStart()
625625 check_error (mpv_set_option_string (hMpv , "alang" , MpvPluginConfig -> Languages .c_str ()));
626626 check_error (mpv_set_option_string (hMpv , "cache" , "no" )); // video stutters if enabled
627627 check_error (mpv_set_option_string (hMpv , "sub-visibility" , MpvPluginConfig -> ShowSubtitles ? "yes" : "no" ));
628+ #if MPV_CLIENT_API_VERSION < MPV_MAKE_VERSION (2 ,2 )
628629 check_error (mpv_set_option_string (hMpv , "sub-forced-only" , "yes" ));
630+ #else
631+ check_error (mpv_set_option_string (hMpv , "sub-forced-events-only" , "yes" ));
632+ #endif
629633 check_error (mpv_set_option_string (hMpv , "sub-auto" , "all" ));
630634 check_error (mpv_set_option_string (hMpv , "hr-seek" , "yes" ));
631635 check_error (mpv_set_option_string (hMpv , "write-filename-in-watch-later-config" , "yes" ));
@@ -642,7 +646,6 @@ void cMpvPlayer::PlayerStart()
642646#ifdef DEBUG
643647 check_error (mpv_set_option_string (hMpv , "log-file" , "/var/log/mpv" ));
644648#endif
645-
646649 if (MpvPluginConfig -> UsePassthrough )
647650 {
648651 check_error (mpv_set_option_string (hMpv , "audio-spdif" , "ac3,dts" ));
0 commit comments