[Ffmpeg-devel] PATCH: make libavformat find codecid for AAC streamsin matroska container.

elupus elupus
Fri Jan 27 22:40:25 CET 2006


 
> -----Original Message-----
> From: elupus [mailto:elupus at ecce.se] 
> Sent: den 27 januari 2006 20:01
> To: 'FFMpeg development discussions and patches'
> Subject: [Ffmpeg-devel] PATCH: make libavformat find codecid 
> for AAC streamsin matroska container.
> 
> Hi, 
> 
> Here is a small patch to allow libavformat to find the codec 
> on AAC streams
> in matroska containers. 
> 
> The defines for the AAC codec's are set like this, 
> 
> 	#define MATROSKA_CODEC_ID_AUDIO_MPEG2        "A_AAC/MPEG2/"
> 	#define MATROSKA_CODEC_ID_AUDIO_MPEG4        "A_AAC/MPEG4/"
> 
> which isn't the full name for the codec's. I.e. it normally 
> has some more
> extension to it like MAIN, LC... 
> 
> Anyway, this patch fixes so that when the codec_id is 
> compared to these
> defines, only the given length is compared (which I think was 
> the original
> idea). I suppose some more information could be gotten from that extra
> information, but I think this should be enough.
> 
> Cheers
> 
> /Joakim
> 

Found a bug report about this in the tracker, didn't see it before. Suppose
using sizeof(MATROSKA_CODEC_ID_AUDIO_MPEGX)-1 would be neater than strlen if
that works.. Didn't know you could do sizeof on constant strings.

http://sourceforge.net/tracker/index.php?func=detail&aid=1399097&group_id=16
082&atid=116082







More information about the ffmpeg-devel mailing list