summaryrefslogtreecommitdiffstats
path: root/mplayer.c
diff options
context:
space:
mode:
authoralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-12-08 12:14:32 +0000
committeralex <alex@b3059339-0415-0410-9bf9-f77b7e298cf2>2003-12-08 12:14:32 +0000
commite7d9078afcad18cae14e4653b1e945926471fbac (patch)
treebcc99f41030e05c9110aeb24e63aa27dbf76b188 /mplayer.c
parenta6bd35c9a2d7618b5d9eeb17751e1fd8fddf04bf (diff)
downloadmpv-e7d9078afcad18cae14e4653b1e945926471fbac.tar.bz2
mpv-e7d9078afcad18cae14e4653b1e945926471fbac.tar.xz
Fontconfig support based on patch by Arwed von Merkatz <v.merkatz@gmx.net>, but slightly reworked
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@11581 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'mplayer.c')
-rw-r--r--mplayer.c19
1 files changed, 15 insertions, 4 deletions
diff --git a/mplayer.c b/mplayer.c
index dea449203b..8badd1812c 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -288,6 +288,9 @@ extern int vo_flags;
// sub:
char *font_name=NULL;
+#ifdef HAVE_FONTCONFIG
+int font_fontconfig=0;
+#endif
float font_factor=0.75;
char **sub_name=NULL;
float sub_delay=0;
@@ -1058,8 +1061,15 @@ if(!parse_codec_cfg(get_path("codecs.conf"))){
//------ load global data first ------
-#ifdef USE_OSD
// check font
+#ifdef USE_OSD
+#ifdef HAVE_FREETYPE
+ init_freetype();
+#endif
+#ifdef HAVE_FONTCONFIG
+ if(!font_fontconfig)
+ {
+#endif
if(font_name){
vo_font=read_font_desc(font_name,font_factor,verbose>1);
if(!vo_font) mp_msg(MSGT_CPLAYER,MSGL_ERR,MSGTR_CantLoadFont,font_name);
@@ -1069,9 +1079,8 @@ if(!parse_codec_cfg(get_path("codecs.conf"))){
if(!vo_font)
vo_font=read_font_desc(MPLAYER_DATADIR "/font/font.desc",font_factor,verbose>1);
}
-#ifdef HAVE_FREETYPE
- if (!vo_font)
- init_freetype();
+#ifdef HAVE_FONTCONFIG
+ }
#endif
#endif
vo_init_osd();
@@ -1373,7 +1382,9 @@ if(stream->type==STREAMTYPE_DVD){
#endif
// CACHE2: initial prefill: 20% later: 5% (should be set by -cacheopts)
+#ifdef HAS_DVBIN_SUPPORT
goto_enable_cache:
+#endif
if(stream_cache_size>0){
current_module="enable_cache";
if(!stream_enable_cache(stream,stream_cache_size*1024,stream_cache_size*1024/5,stream_cache_size*1024/20))