[FFmpeg-devel] [PATCH] Add a parser for DNET (byte-swapped AC3).

Anssi Hannula anssi.hannula
Wed Mar 2 22:17:39 CET 2011

On 02.03.2011 22:23, Kostya wrote:
> On Wed, Mar 02, 2011 at 08:12:15PM +0000, M?ns Rullg?rd wrote:
>> Reimar D?ffinger <Reimar.Doeffinger at gmx.de> writes:
>>> Currently we simply byte-swap DNET directly in the Real demuxer,
>>> however this is not generally possible/correct since which two bytes we
>>> need to swap depends on whether the header starts on an even or an odd
>>> byte.
>>> Not useful on its own within FFmpeg, but could e.g. be used together
>>> with a byte-swap bitstream filter or a modified AC3-decoder to implement
>>> more robust DNET support.
>> Where does the name DNET come from?
>>> @@ -390,6 +390,7 @@ enum CodecID {
>>>      CODEC_ID_QDMC,
>>> +    CODEC_ID_DNET,
>> I don't think a new codec ID is called for.  Couldn't it be handled the
>> same way as byte-swapped DTS?
> I think it can and should - and there's AC3-in-WAV too to be supported.

Note that AC3-in-WAV is actually AC3-in-IEC61937-in-WAV, and the
byteswapping is technically performed when doing IEC61937-in-WAV, so the
encapsulated AC3 stream in fact is in standard endianness when outputted
from a IEC61937 demuxer.

Anssi Hannula

More information about the ffmpeg-devel mailing list