[Ffmpeg-devel] [RFC] SMPTE 302M AES 3 stream in mpeg ts

Baptiste Coudurier baptiste.coudurier
Sat Sep 16 14:27:02 CEST 2006


Hi

This patch add support to play S302M streams in mpeg ts.
Actually daud demuxer was S302M stream demuxer. I implemented bitstream
parsing using a "shadow" parser, since S302M streams can carry lpcm
audio, ac3, mp3, dolby e...

It's quite ugly and of course parser can be simplified, its just a proof
of concept about which I would like to have opinions.

I have a problem concerning the parser. It seems that after
av_find_stream_info, the next pkt gotten from mpegts av_read_packet is
not the first one, which would contain 302M header. Basically S302M AES3
frames are split across ~170 packets. Im sure Im missing something, but
I can't really find out.

example:
  libavformat version: 50.5.0
  built on Sep 16 2006 14:12:50, gcc: 4.1.2 20060901 (prerelease)
(Debian 4.1.1-13)
fetch pts 6768256878 (av_parser_parser fetch_timestamp == 1)

[...]
Stream mapping:
  Stream #0.0 -> #0.0
  Stream #0.1 -> #0.1
Press [q] to stop encoding
fetch pts -9223372036854775808 (av_parser_parser fetch_timestamp == 1)
parser: in:-9223372036854775808, -9223372036854775808,
out:-9223372036854775808, -9223372036854775808, in:184 out:0 id:65549

[...]
parser: in:-9223372036854775808, -9223372036854775808,
out:-9223372036854775808, -9223372036854775808, in:184 out:0 id:65549
parser: in:-9223372036854775808, -9223372036854775808,
out:-9223372036854775808, -9223372036854775808, in:184 out:0 id:65549
parser: in:-9223372036854775808, -9223372036854775808,
out:-9223372036854775808, -9223372036854775808, in:34 out:0 id:65549
parser: in:6768256878, -9223372036854775808, out:-9223372036854775808,
-9223372036854775808, in:166 out:0 id:65549 < that's actually the good
first pts.

Why hasn't the first pkt real first pts ?

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A.                                    http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: s302m.patch
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20060916/1dacca0a/attachment.txt>



More information about the ffmpeg-devel mailing list