[Mplayer-cvslog] CVS: main mplayer.c,1.791,1.792

Joey Parrish CVS syncmail at mplayerhq.hu
Tue Sep 28 16:00:51 CEST 2004


CVS change done by Joey Parrish CVS

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

Modified Files:
	mplayer.c 
Log Message:
show ogg subtitle language on OSD, if available


Index: mplayer.c
===================================================================
RCS file: /cvsroot/mplayer/main/mplayer.c,v
retrieving revision 1.791
retrieving revision 1.792
diff -u -r1.791 -r1.792
--- mplayer.c	28 Sep 2004 13:51:19 -0000	1.791
+++ mplayer.c	28 Sep 2004 14:00:48 -0000	1.792
@@ -3719,12 +3719,17 @@
 	      language = vobsub_get_id(vo_vobsub, (unsigned int) vobsub_id);
 	  snprintf(osd_text_tmp, 63, "Subtitles: (%d) %s", vobsub_id, language ? language : "unknown");
 	  }
+#ifdef HAVE_OGGVORBIS
 	  if (d_dvdsub && demuxer->type == DEMUXER_TYPE_OGG) {
 	      if (dvdsub_id < 0)
 		snprintf(osd_text_tmp, 63, "Subtitles: (off)");
-	      else
-		snprintf(osd_text_tmp, 63, "Subtitles: (%d)", dvdsub_id);
+	      else {
+		char *lang = demux_ogg_sub_lang(demuxer, dvdsub_id);
+		if (!lang) lang = "unknown";
+		snprintf(osd_text_tmp, 63, "Subtitles: (%d) %s", dvdsub_id, lang);
+	      }
 	  }
+#endif
 #ifdef USE_DVDREAD
 	  if (vo_spudec && (demuxer->type != DEMUXER_TYPE_MATROSKA)) {
 	      char lang[5] = "none";




More information about the MPlayer-cvslog mailing list