Commit 3f95e843 authored by François Revol's avatar François Revol Committed by Michael Niedermayer
Browse files

added MACE (Macintosh Audio Compression/Expansion) 3:1 & 6:1 support

contribution by Laszlo Torok <torokl@alpha.dfmk.hu>
4CC 'MAC3' and 'MAC6' in Quicktime.
It works for mono streams, needs to be fixed for stereo when I get my hands on a stereo sample :)
patch by (François Revol <revol at free dot fr>)

Originally committed as revision 1145 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 9ddd71fc
......@@ -121,6 +121,8 @@ static const CodecTag mov_audio_tags[] = {
{ CODEC_ID_PCM_MULAW, MKTAG('u', 'l', 'a', 'w') }, /* */
{ CODEC_ID_PCM_ALAW, MKTAG('a', 'l', 'a', 'w') }, /* */
{ CODEC_ID_ADPCM_IMA_QT, MKTAG('i', 'm', 'a', '4') }, /* IMA-4 ADPCM */
{ CODEC_ID_MACE3, MKTAG('M', 'A', 'C', '3') }, /* Macintosh Audio Compression and Expansion 3:1 */
{ CODEC_ID_MACE6, MKTAG('M', 'A', 'C', '6') }, /* Macintosh Audio Compression and Expansion 6:1 */
{ CODEC_ID_MP2, MKTAG('.', 'm', 'p', '3') }, /* MPEG layer 3 */ /* sample files at http://www.3ivx.com/showcase.html use this tag */
{ CODEC_ID_MP2, 0x6D730055 }, /* MPEG layer 3 */
......@@ -829,9 +831,11 @@ static int parse_stco(const MOVParseTableEntry *parse_table, ByteIOContext *pb,
} else
return -1;
#ifdef DEBUG
/*
for(i=0; i<entries; i++) {
printf("chunk offset=0x%Lx\n", sc->chunk_offsets[i]);
}
*/
#endif
return 0;
}
......
......@@ -16,7 +16,7 @@ OBJS= common.o utils.o mem.o allcodecs.o \
motion_est.o imgconvert.o imgresample.o msmpeg4.o \
mpeg12.o h263dec.o svq1.o rv10.o mpegaudiodec.o pcm.o simple_idct.o \
ratecontrol.o adpcm.o eval.o dv.o error_resilience.o \
wmadec.o fft.o mdct.o
wmadec.o fft.o mdct.o mace.o
ASM_OBJS=
# currently using liba52 for ac3 decoding
......
......@@ -76,6 +76,8 @@ void avcodec_register_all(void)
register_avcodec(&mp3_decoder);
register_avcodec(&wmav1_decoder);
register_avcodec(&wmav2_decoder);
register_avcodec(&mace3_decoder);
register_avcodec(&mace6_decoder);
#ifdef CONFIG_AC3
register_avcodec(&ac3_decoder);
#endif
......
......@@ -5,8 +5,8 @@
#define LIBAVCODEC_VERSION_INT 0x000406
#define LIBAVCODEC_VERSION "0.4.6"
#define LIBAVCODEC_BUILD 4633
#define LIBAVCODEC_BUILD_STR "4633"
#define LIBAVCODEC_BUILD 4634
#define LIBAVCODEC_BUILD_STR "4634"
enum CodecID {
CODEC_ID_NONE,
......@@ -32,6 +32,8 @@ enum CodecID {
CODEC_ID_DVAUDIO,
CODEC_ID_WMAV1,
CODEC_ID_WMAV2,
CODEC_ID_MACE3,
CODEC_ID_MACE6,
/* various pcm "codecs" */
CODEC_ID_PCM_S16LE,
......@@ -805,6 +807,8 @@ extern AVCodec wmav2_decoder;
extern AVCodec mjpeg_decoder;
extern AVCodec mp2_decoder;
extern AVCodec mp3_decoder;
extern AVCodec mace3_decoder;
extern AVCodec mace6_decoder;
/* pcm codecs */
#define PCM_CODEC(id, name) \
......
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment