changeset 29069:dc5daa853163

Set the forced_subs_only value correctly whenever a new spudec is created.
author reimar
date Mon, 30 Mar 2009 17:05:39 +0000
parents b58c687a3078
children e64e543ed6b3
files mencoder.c mplayer.c
diffstat 2 files changed, 6 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mencoder.c	Mon Mar 30 12:23:28 2009 +0000
+++ b/mencoder.c	Mon Mar 30 17:05:39 2009 +0000
@@ -698,6 +698,8 @@
                            sh_video->disp_w, sh_video->disp_h, NULL, 0);
 }
 #endif
+if (vo_spudec)
+  spudec_set_forced_subs_only(vo_spudec, forced_subs_only);
 }
 
 ostream = open_output_stream(out_filename, 0);
--- a/mplayer.c	Mon Mar 30 12:23:28 2009 +0000
+++ b/mplayer.c	Mon Mar 30 17:05:39 2009 +0000
@@ -1125,8 +1125,10 @@
     spudec_set_font_factor(vo_spudec,font_factor);
   }
 
-  if (vo_spudec!=NULL)
+  if (vo_spudec!=NULL) {
     initialized_flags|=INITIALIZED_SPUDEC;
+    mp_property_do("sub_forced_only", M_PROPERTY_SET, &forced_subs_only, mpctx);
+  }
 }
 
 /*
@@ -3066,6 +3068,7 @@
     if(vo_vobsub){
       initialized_flags|=INITIALIZED_VOBSUB;
       vobsub_set_from_lang(vo_vobsub, dvdsub_lang);
+      mp_property_do("sub_forced_only", M_PROPERTY_SET, &forced_subs_only, mpctx);
 
       // setup global sub numbering
       mpctx->global_sub_indices[SUB_SOURCE_VOBSUB] = mpctx->global_sub_size; // the global # of the first vobsub.