player: load encoding-profiles.conf before the main config

Otherwise one can't add profiles based on the encoding profiles.
This commit is contained in:
wm4 2014-01-01 19:25:52 +01:00
parent bbdd030a58
commit 9169737a47
1 changed files with 7 additions and 7 deletions

View File

@ -57,6 +57,13 @@ bool mp_parse_cfgfiles(struct MPContext *mpctx)
bool r = true;
char *conffile;
// The #if is a stupid hack to avoid errors if libavfilter is not available.
#if HAVE_VF_LAVFI && HAVE_ENCODING
conffile = mp_find_config_file(tmp, mpctx->global, "encoding-profiles.conf");
if (conffile && mp_path_exists(conffile))
m_config_parse_config_file(mpctx->mconfig, conffile, 0);
#endif
if (m_config_parse_config_file(conf, MPLAYER_CONFDIR "/mpv.conf", 0) < 0) {
r = false;
goto done;
@ -77,13 +84,6 @@ bool mp_parse_cfgfiles(struct MPContext *mpctx)
}
}
// The #if is a stupid hack to avoid errors if libavfilter is not available.
#if HAVE_VF_LAVFI && HAVE_ENCODING
conffile = mp_find_config_file(tmp, mpctx->global, "encoding-profiles.conf");
if (conffile && mp_path_exists(conffile))
m_config_parse_config_file(mpctx->mconfig, conffile, 0);
#endif
done:
talloc_free(tmp);
return r;