[MPlayer-users] switch_audio on *.ts files

Reimar Döffinger Reimar.Doeffinger at gmx.de
Fri Jun 19 15:06:16 CEST 2009


On Thu, Jun 18, 2009 at 11:31:13AM +0200, Nico Sabbi wrote:
> > Full log attached (and compressed, it's huge). BTW, is it necessary
> > that those ID_VIDEO_ID and ID_AUDIO_ID lines appear so many times?
> 
> it's annoying, but adding even more code to handle such cases is even 
> more so. Anyway, patch welcome.

Well, it leaves the issue of the language being printed again and again,
but this seems to "fix" it. One "annoyance" is that now all the
languages are printed first and only then the ID_VIDEO_ID and
ID_AUDIO_ID.
To fix both, the ..._LANG printing would have to be moved to
ts_add_stream or better to new_sh_...
Index: libmpdemux/demux_ts.c
===================================================================
--- libmpdemux/demux_ts.c       (revision 29371)
+++ libmpdemux/demux_ts.c       (working copy)
@@ -700,14 +700,12 @@
 
                        if(is_video)
                        {
-                               mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_VIDEO_ID=%d\n", es.pid);
                                chosen_pid = (req_vpid == es.pid);
                                if((! chosen_pid) && (req_vpid > 0))
                                        continue;
                        }
                        else if(is_audio)
                        {
-                               mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_AUDIO_ID=%d\n", es.pid);
                                if (es.lang[0] > 0)
                                        mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_AID_%d_LANG=%s\n", es.pid, es.lang);
                                if(req_apid > 0)
@@ -727,7 +725,6 @@
                        }
                        else if(is_sub)
                        {
-                               mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_SUBTITLE_ID=%d\n", es.pid);
                                if (es.lang[0] > 0)
                                        mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_SID_%d_LANG=%s\n", es.pid, es.lang);
                                chosen_pid = (req_spid == es.pid);



More information about the MPlayer-users mailing list