mirror of https://github.com/odrling/Aegisub
Let ffms2 set number of video decoding threads automatically. Patch by TheRyuu.
Originally committed to SVN as r5491.
This commit is contained in:
parent
6ffc6de6b6
commit
239dbb08c1
|
@ -169,7 +169,7 @@ void OptionsManager::LoadDefaults(bool onlyDefaults,bool doOverride) {
|
||||||
SetText(_T("Video Provider"),_T(DEFAULT_PROVIDER_VIDEO),1945);
|
SetText(_T("Video Provider"),_T(DEFAULT_PROVIDER_VIDEO),1945);
|
||||||
#endif
|
#endif
|
||||||
SetBool(_T("FFmpeg allow unsafe seeking"),false);
|
SetBool(_T("FFmpeg allow unsafe seeking"),false);
|
||||||
SetInt(_T("FFmpegSource decoding threads"),1);
|
SetInt(_T("FFmpegSource threads"),-1);
|
||||||
SetBool(_T("Allow Ancient Avisynth"),false,1700);
|
SetBool(_T("Allow Ancient Avisynth"),false,1700);
|
||||||
#ifdef __WINDOWS__
|
#ifdef __WINDOWS__
|
||||||
SetText(_T("Subtitles Provider"),_T("csri/vsfilter_textsub"),1700);
|
SetText(_T("Subtitles Provider"),_T("csri/vsfilter_textsub"),1700);
|
||||||
|
|
|
@ -197,10 +197,8 @@ void FFmpegSourceVideoProvider::LoadVideo(wxString filename) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// set thread count
|
//number of threads automatically determined by ffms2 if given a value < 1
|
||||||
int Threads = Options.AsInt(_T("FFmpegSource decoding threads"));
|
int Threads = Options.AsInt(_T("FFmpegSource threads"));
|
||||||
if (Threads < 1)
|
|
||||||
throw _T("FFmpegSource video provider: invalid decoding thread count");
|
|
||||||
|
|
||||||
// set seekmode
|
// set seekmode
|
||||||
// TODO: give this its own option?
|
// TODO: give this its own option?
|
||||||
|
|
Loading…
Reference in New Issue