Mercurial > mplayer.hg
changeset 9884:d7b86f7d1406
turn most of the subtitle matching fuzziness off by default
author | henry |
---|---|
date | Tue, 08 Apr 2003 20:41:20 +0000 |
parents | 3a407acefec5 |
children | 98712065a08d |
files | DOCS/en/mplayer.1 cfg-common.h subreader.c subreader.h |
diffstat | 4 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/DOCS/en/mplayer.1 Tue Apr 08 18:05:41 2003 +0000 +++ b/DOCS/en/mplayer.1 Tue Apr 08 20:41:20 2003 +0000 @@ -1081,6 +1081,10 @@ Disables any kind of text post processing done after loading the subtitles. Used for debug purposes. .TP +.B \-subfuzzy +Relax when trying to find matching subtitles. Loads all subtitles in +the current directory, allowing to select the right ones during playing. +.TP .B \-vobsub <vobsub\ file\ without\ extension> Specify the VobSub files that are to be used for subtitle. This is the full pathname without extensions, i.e.\& without the '.idx',
--- a/cfg-common.h Tue Apr 08 18:05:41 2003 +0000 +++ b/cfg-common.h Tue Apr 08 20:41:20 2003 +0000 @@ -212,6 +212,7 @@ {"sub-bg-color", &sub_bg_color, CONF_TYPE_INT, CONF_RANGE, 0, 255, NULL}, {"sub-bg-alpha", &sub_bg_alpha, CONF_TYPE_INT, CONF_RANGE, 0, 255, NULL}, {"sub-no-text-pp", &sub_no_text_pp, CONF_TYPE_FLAG, 0, 0, 1, NULL}, + {"subfuzzy", &subfuzzy_enabled, CONF_TYPE_FLAG, 0, 0, 1, NULL}, #endif #ifdef USE_OSD {"font", &font_name, CONF_TYPE_STRING, 0, 0, 0, NULL},
--- a/subreader.c Tue Apr 08 18:05:41 2003 +0000 +++ b/subreader.c Tue Apr 08 20:41:20 2003 +0000 @@ -40,6 +40,8 @@ int sub_no_text_pp=0; // 1 => do not apply text post-processing // like {\...} elimination in SSA format. +int subfuzzy_enabled=0; // be _really_ fuzzy when looking for subtitles + /* Use the SUB_* constant defined in the header file */ int sub_format=SUB_INVALID; #ifdef USE_SORTSUB @@ -1696,7 +1698,7 @@ } else { // doesn't contain the movie name // don't try in the mplayer subtitle directory - if (j == 0) { + if ((j == 0) && subfuzzy_enabled) { sprintf(tmpresult, "%s%s", f_dir, de->d_name); if ((f = fopen(tmpresult, "rt"))) { fclose(f);