# HG changeset patch # User alexc # Date 1268006450 0 # Node ID 20ed96c29062b205de4389be9bb6a4579863f914 # Parent faa085c983d520e20b926f14c1f4569c1003ba3c av_find_stream_info(): Add a workaround for backwards compatible HE-AAC signaling. The sample rate, frame size, and channel count from the container are not reliable when backwards compatible signaling is used. diff -r faa085c983d5 -r 20ed96c29062 avformat.h --- a/avformat.h Sun Mar 07 23:10:18 2010 +0000 +++ b/avformat.h Mon Mar 08 00:00:50 2010 +0000 @@ -22,7 +22,7 @@ #define AVFORMAT_AVFORMAT_H #define LIBAVFORMAT_VERSION_MAJOR 52 -#define LIBAVFORMAT_VERSION_MINOR 54 +#define LIBAVFORMAT_VERSION_MINOR 55 #define LIBAVFORMAT_VERSION_MICRO 0 #define LIBAVFORMAT_VERSION_INT AV_VERSION_INT(LIBAVFORMAT_VERSION_MAJOR, \ diff -r faa085c983d5 -r 20ed96c29062 utils.c --- a/utils.c Sun Mar 07 23:10:18 2010 +0000 +++ b/utils.c Mon Mar 08 00:00:50 2010 +0000 @@ -2116,6 +2116,11 @@ for(i=0;inb_streams;i++) { st = ic->streams[i]; + if (st->codec->codec_id == CODEC_ID_AAC) { + st->codec->sample_rate = 0; + st->codec->frame_size = 0; + st->codec->channels = 0; + } if(st->codec->codec_type == CODEC_TYPE_VIDEO){ /* if(!st->time_base.num) st->time_base= */