[FFmpeg-devel] [PATCH] Proper parsing of DTS-HD MA streams - Patch to TS Parser

Robert McNamara robert.mcnamara
Thu Nov 27 22:37:54 CET 2008

Updating this subject to correctly reflect the contents.  I am attaching a
patch to handle the first of two hurdles for solving the problem of proper
parsing of DTS HD MA audio.  This is a rework of a previous patch discussed
in June.  I'll try to briefly summarize the issues at that time.

At the time, there was no means of handling TrueHD, and there was some
question as to whether the E-AC3 and AC3 stream types should be handles
seperately.  As both TrueHD/MLP and E-AC3 are handled properly by FFMpeg
now, it seems appropriate to bring this back to the table.  The stream type
definitions are are outlined here:


I have added a case for the TrueHD streams to be handled by CODEC_ID_MLP.
As we know that E-AC3 is now handled by CODEC_ID_AC3, I have added that to
the EAC3 stream handling to that case.  Finally, the issues with properly
decoding DTS-HD are parsing ones for dca_parser.  It is useful in working
towards that goal to be able to see the streams properly in ffmpeg, so I
have added the DTS-HD definitions to the DTS parser case.

I have tested all stream types with real world examples from my own
collection and from samples provided by madshi.  Between that and the patent
application delineating the stream types, I am hoping that this will be
sufficient to get these changes committed in furtherance of working DTS-HD
MA playback.

I am by no means a programmer so I beg everyone's pardon for any stupid
mistakes, and beleive me when I say you couldn't make me any more
embarrassed about my shortcoming in that department than I already am.  :)
To anyone celebrating the holiday, a happy thanksgiving.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: mpegtsparser_hdformats.diff
Type: text/x-patch
Size: 1856 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20081127/99269ba9/attachment.bin>

More information about the ffmpeg-devel mailing list