summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libavcodec/avcodec.h2
-rw-r--r--libavcodec/faad.c2
-rw-r--r--libavformat/avidec.c3
-rw-r--r--libavformat/matroska.c5
-rw-r--r--libavformat/riff.c2
-rw-r--r--libavformat/rtp.c6
-rw-r--r--libavformat/rtsp.c2
7 files changed, 14 insertions, 8 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index 6330322..ac128ec 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -206,7 +206,9 @@ enum CodecID {
CODEC_ID_MP2= 0x15000,
CODEC_ID_MP3, /* prefered ID for MPEG Audio layer 1, 2 or3 decoding */
CODEC_ID_AAC,
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
CODEC_ID_MPEG4AAC,
+#endif
CODEC_ID_AC3,
CODEC_ID_DTS,
CODEC_ID_VORBIS,
diff --git a/libavcodec/faad.c b/libavcodec/faad.c
index fcea1c8..df33ea0 100644
--- a/libavcodec/faad.c
+++ b/libavcodec/faad.c
@@ -326,7 +326,9 @@ AVCodec name ## _decoder = { \
// FIXME - raw AAC files - maybe just one entry will be enough
AAC_CODEC(CODEC_ID_AAC, aac);
+#if LIBAVCODEC_VERSION_INT < ((52<<16)+(0<<8)+0)
// If it's mp4 file - usually embeded into Qt Mov
AAC_CODEC(CODEC_ID_MPEG4AAC, mpeg4aac);
+#endif
#undef AAC_CODEC
diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index 457cda8..dfbe5c6 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -443,6 +443,9 @@ static int avi_read_header(AVFormatContext *s, AVFormatParameters *ap)
/* special case time: To support Xan DPCM, hardcode
* the format if Xxan is the video codec */
st->need_parsing = 1;
+ /* ADTS header is in extradata, AAC without header must be stored as exact frames, parser not needed and it will fail */
+ if (st->codec->codec_id == CODEC_ID_AAC && st->codec->extradata_size)
+ st->need_parsing = 0;
/* force parsing as several audio frames can be in
one packet */
if (xan_video)
diff --git a/libavformat/matroska.c b/libavformat/matroska.c
index b798275..9de257c 100644
--- a/libavformat/matroska.c
+++ b/libavformat/matroska.c
@@ -222,8 +222,7 @@ static CodecTags codec_tags[]={
{"A_AC3" , CODEC_ID_AC3},
{"A_DTS" , CODEC_ID_DTS},
{"A_VORBIS" , CODEC_ID_VORBIS},
- {"A_AAC/MPEG2/" , CODEC_ID_AAC},
- {"A_AAC/MPEG4/" , CODEC_ID_MPEG4AAC},
+ {"A_AAC/" , CODEC_ID_AAC},
{"A_WAVPACK4" , CODEC_ID_WAVPACK},
{NULL , CODEC_ID_NONE}
/* TODO: AC3-9/10 (?), Real, Musepack, Quicktime */
@@ -2246,7 +2245,7 @@ matroska_read_header (AVFormatContext *s,
}
- if (codec_id==CODEC_ID_AAC || codec_id==CODEC_ID_MPEG4AAC) {
+ if (codec_id==CODEC_ID_AAC) {
MatroskaAudioTrack *audiotrack = (MatroskaAudioTrack *) track;
int profile = matroska_aac_profile(track->codec_id);
int sri = matroska_aac_sri(audiotrack->internal_samplerate);
diff --git a/libavformat/riff.c b/libavformat/riff.c
index ec9abda..fb2a7fc 100644
--- a/libavformat/riff.c
+++ b/libavformat/riff.c
@@ -186,7 +186,7 @@ const CodecTag codec_wav_tags[] = {
{ CODEC_ID_WMAV1, 0x160 },
{ CODEC_ID_WMAV2, 0x161 },
{ CODEC_ID_AAC, 0x706d },
- { CODEC_ID_MPEG4AAC, 0xff },
+ { CODEC_ID_AAC, 0xff },
{ CODEC_ID_VORBIS, ('V'<<8)+'o' }, //HACK/FIXME, does vorbis in WAV/AVI have an (in)official id?
{ CODEC_ID_SONIC, 0x2048 },
{ CODEC_ID_SONIC_LS, 0x2048 },
diff --git a/libavformat/rtp.c b/libavformat/rtp.c
index 7bef395..37a2862 100644
--- a/libavformat/rtp.c
+++ b/libavformat/rtp.c
@@ -186,7 +186,7 @@ AVRtpPayloadType_t AVRtpPayloadTypes[]=
RTPDynamicProtocolHandler *RTPFirstDynamicPayloadHandler= NULL;
static RTPDynamicProtocolHandler mp4v_es_handler= {"MP4V-ES", CODEC_TYPE_VIDEO, CODEC_ID_MPEG4};
-static RTPDynamicProtocolHandler mpeg4_generic_handler= {"mpeg4-generic", CODEC_TYPE_AUDIO, CODEC_ID_MPEG4AAC};
+static RTPDynamicProtocolHandler mpeg4_generic_handler= {"mpeg4-generic", CODEC_TYPE_AUDIO, CODEC_ID_AAC};
static void register_dynamic_payload_handler(RTPDynamicProtocolHandler *handler)
{
@@ -564,7 +564,7 @@ static void finalize_packet(RTPDemuxContext *s, AVPacket *pkt, uint32_t timestam
pkt->pts = addend + delta_timestamp;
}
break;
- case CODEC_ID_MPEG4AAC:
+ case CODEC_ID_AAC:
case CODEC_ID_H264:
case CODEC_ID_MPEG4:
pkt->pts = timestamp;
@@ -694,7 +694,7 @@ int rtp_parse_packet(RTPDemuxContext *s, AVPacket *pkt,
// moved from below, verbatim. this is because this section handles packets, and the lower switch handles
// timestamps.
// TODO: Put this into a dynamic packet handler...
- case CODEC_ID_MPEG4AAC:
+ case CODEC_ID_AAC:
if (rtp_parse_mp4_au(s, buf))
return -1;
{
diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 6c01f5e..4c99a17 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -251,7 +251,7 @@ static void sdp_parse_fmtp_config(AVCodecContext *codec, char *attr, char *value
{
switch (codec->codec_id) {
case CODEC_ID_MPEG4:
- case CODEC_ID_MPEG4AAC:
+ case CODEC_ID_AAC:
if (!strcmp(attr, "config")) {
/* decode the hexa encoded parameter */
int len = hex_to_data(NULL, value);
OpenPOWER on IntegriCloud