mirror of https://github.com/mpv-player/mpv
turn most of the subtitle matching fuzziness off by default
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@9885 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
a3eaf74b6f
commit
819515d6fb
|
@ -1081,6 +1081,10 @@ Tells MPlayer to handle the subtitle file as UTF8.
|
|||
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',
|
||||
|
|
|
@ -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},
|
||||
|
|
|
@ -40,6 +40,8 @@ static int sub_slacktime = 20000; //20 sec
|
|||
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 @@ char** sub_filenames(char* path, char *fname)
|
|||
} 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);
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
|
||||
extern int suboverlap_enabled;
|
||||
extern int sub_no_text_pp; // disable text post-processing
|
||||
extern int subfuzzy_enabled;
|
||||
|
||||
// subtitle formats
|
||||
#define SUB_INVALID -1
|
||||
|
|
Loading…
Reference in New Issue