changeset 23742:93c871be0258

Use -font for subtitles when -subfont is not given, patch by kiriuja <mplayer-patches AT en-directo DOT net>
author zuxy
date Wed, 11 Jul 2007 10:01:54 +0000
parents 5e70169314cb
children eb8cc193b661
files libvo/sub.c
diffstat 1 files changed, 8 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/sub.c	Wed Jul 11 01:49:43 2007 +0000
+++ b/libvo/sub.c	Wed Jul 11 10:01:54 2007 +0000
@@ -835,7 +835,10 @@
     if (force_load_font) {
 	force_load_font = 0;
         load_font_ft(dxs, dys, &vo_font, font_name);
-        load_font_ft(dxs, dys, &sub_font, sub_font_name);
+	if (sub_font_name)
+	    load_font_ft(dxs, dys, &sub_font, sub_font_name);
+	else
+	    sub_font = vo_font;
 	prev_dxs = dxs;
 	prev_dys = dys;
 	defer_counter = 0;
@@ -843,7 +846,10 @@
        if (!vo_font) 
            load_font_ft(dxs, dys, &vo_font, font_name);
        if (!sub_font) 
-           load_font_ft(dxs, dys, &sub_font, sub_font_name);
+           if (sub_font_name)
+               load_font_ft(dxs, dys, &sub_font, sub_font_name);
+           else
+               sub_font = vo_font;
     }
 #endif