diff options
author | Peter Ross <pross@xvid.org> | 2007-10-24 20:49:42 +0000 |
---|---|---|
committer | Aurelien Jacobs <aurel@gnuage.org> | 2007-10-24 20:49:42 +0000 |
commit | e7583962687adf44b4e6b5556a296f37485c7c8b (patch) | |
tree | 7eccd7643ae8b71792c9ea9862a84d1d62ec1896 /libavformat/electronicarts.c | |
parent | d2bbb2f743e253869316db3e45f639d09285f583 (diff) | |
download | ffmpeg-e7583962687adf44b4e6b5556a296f37485c7c8b.tar.gz |
EA ADPCM R1, R2 and R3 decoder
original patch by Peter Ross
Originally committed as revision 10856 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/electronicarts.c')
-rw-r--r-- | libavformat/electronicarts.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavformat/electronicarts.c b/libavformat/electronicarts.c index b4c14e0080..08c2840656 100644 --- a/libavformat/electronicarts.c +++ b/libavformat/electronicarts.c @@ -149,6 +149,16 @@ static int process_audio_header_elements(AVFormatContext *s) switch (compression_type) { case 0: ea->audio_codec = CODEC_ID_PCM_S16LE; break; case 7: ea->audio_codec = CODEC_ID_ADPCM_EA; break; + case -1: + switch (revision) { + case 1: ea->audio_codec = CODEC_ID_ADPCM_EA_R1; break; + case 2: ea->audio_codec = CODEC_ID_ADPCM_EA_R2; break; + case 3: ea->audio_codec = CODEC_ID_ADPCM_EA_R3; break; + default: + av_log(s, AV_LOG_ERROR, "unsupported stream type; revision=%i\n", revision); + return 0; + } + break; default: av_log(s, AV_LOG_ERROR, "unsupported stream type; compression_type=%i\n", compression_type); return 0; |