[FFmpeg-devel] LATM bit stream filtering questions

Paul Kendall paul
Fri May 8 11:22:16 CEST 2009

I have re-written the LATM code as a bit stream filter and a matching parser.

I have applied Baptiste's patch, "Bitstream filtering API in libavformat"

I have modified mpegts.c so that stream 0x11 sets the codec type to
CODEC_ID_AAC_LATM and enrolls the LATM filter.

The parser is registered with type CODEC_ID_AAC_LATM.

Using ffplay, the stream is parsed, sent to the filter, then sent to to the
libfaad decoder (I have added a CODEC_ID_AAC_LATM), and everything is
working nicely.

I know that we want this to go via the ffaac implementation, but at the
moment I only have HE-AAC.

I have made it so the parser, resets the codec_id to CODE_ID_AAC, and that
works for the first phase, but then starts using the wrong parser (the AAC 

So, in a perfect world, mpegts.c would set the codec_id to CODEC_ID_AAC.
How would this then get parsed by the LATM parser? Should I modify the
current AAC parser to make it do both ADTS & LATM? What is the right

Do we need to separate the parser from the codec in the stream? This would
mean that a stream could select a parser, filter chain, and decoder. Perhaps
this is a more versatile solution.



More information about the ffmpeg-devel mailing list