OSDN Git Service

Set stream type to ac3 if registration descriptor is present.
authorBaptiste Coudurier <baptiste.coudurier@gmail.com>
Sun, 12 Apr 2009 02:39:16 +0000 (02:39 +0000)
committerBaptiste Coudurier <baptiste.coudurier@gmail.com>
Sun, 12 Apr 2009 02:39:16 +0000 (02:39 +0000)
Based on patch by Nico Sabi, nicola dot sabbi at poste dot it

Originally committed as revision 18457 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavformat/mpegts.c

index 50d1ffa..8530cc8 100644 (file)
@@ -601,6 +601,8 @@ static void pmt_cb(MpegTSFilter *filter, const uint8_t *section, int section_len
                 reg_desc = bytestream_get_le32(&p);
                 if(reg_desc == AV_RL32("drac"))
                     has_dirac_descr = 1;
+                else if(reg_desc == AV_RL32("AC-3"))
+                    stream_type = STREAM_TYPE_AUDIO_AC3;
                 break;
             default:
                 break;