if option -sub filename.utf then switch sub_utf8 on

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1605 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
atlka 2001-08-21 12:09:39 +00:00
parent 9402d2456a
commit ca34fb6b74
2 changed files with 12 additions and 1 deletions

View File

@ -25,7 +25,14 @@ There are many ways to get it:
Note: currently available fonts are only for limited iso 8859-1/2 support,
and there is a few special version for korean, russian etc codepages.
You'd better building font yourself with tool mentioned above.
Font should have appropriate font.desc file which maps unicode font
positions to the actual code page of the subtitles text. Other solution
is to have subtitles encoded in utf8 encoding and use -utf8 option
or just name the subtitles file <video_name>.utf and have it in the same
dir as the video file. Recoding from different codepages to utf8 could be
done by using konwert (debian) or iconv (RedHat) programs.
some usefull URLs:
ftp://ftp.mplayerhq.hu/MPlayer/releases/ - ISO fonts, OBSOLETED!
ftp://ftp.mplayerhq.hu/MPlayer/contrib/fonts/ - various fonts by users

View File

@ -589,6 +589,10 @@ if(!parse_codec_cfg(get_path("codecs.conf"))){
#ifdef USE_SUB
// check .sub
if(sub_name){
int l=strlen(sub_name);
if ((l>4) && ((0==strcmp(&sub_name[l-4],".utf"))
||(0==strcmp(&sub_name[l-4],".UTF"))))
sub_utf8=1;
subtitles=sub_read_file(sub_name);
if(!subtitles) mp_msg(MSGT_CPLAYER,MSGL_ERR,MSGTR_CantLoadSub,sub_name);
} else {