[Mplayer-cvslog] CVS: main/libmpdemux demux_ogg.c,1.48,1.49

Moritz Bunkus CVS syncmail at mplayerhq.hu
Thu Apr 29 23:01:12 CEST 2004


CVS change done by Moritz Bunkus CVS

Update of /cvsroot/mplayer/main/libmpdemux
In directory mail:/var2/tmp/cvs-serv31756

Modified Files:
	demux_ogg.c 
Log Message:
Leave the subs uninitialized and not "forcefully off" if the user hasn't chosen a stream with -sid. If he used -slang then we need the comment packet which might be found after demux_ogg_open has finished.

Index: demux_ogg.c
===================================================================
RCS file: /cvsroot/mplayer/main/libmpdemux/demux_ogg.c,v
retrieving revision 1.48
retrieving revision 1.49
diff -u -r1.48 -r1.49
--- demux_ogg.c	23 Apr 2004 22:30:18 -0000	1.48
+++ demux_ogg.c	29 Apr 2004 21:01:09 -0000	1.49
@@ -961,9 +961,12 @@
     demuxer->audio->id = -2;
   else
     demuxer->audio->id = audio_id;
-  if(!n_text || (text_id < 0))
+  /* Disable the subs only if there are no text streams at all.
+     Otherwise the stream to display might be chosen later when the comment
+     packet is encountered and the user used -slang instead of -sid. */
+  if(!n_text)
     demuxer->sub->id = -2;
-  else
+  else if (text_id >= 0)
     demuxer->sub->id = text_id;
 
   ogg_d->final_granulepos=0;




More information about the MPlayer-cvslog mailing list