summaryrefslogtreecommitdiffstats
path: root/media/ffmpeg
diff options
context:
space:
mode:
authormikhal <mikhal@chromium.org>2015-01-28 18:50:48 -0800
committerCommit bot <commit-bot@chromium.org>2015-01-29 02:52:09 +0000
commit3e0fe16bc2c849c91530b0864b944bc5d736f9c7 (patch)
tree3717b43307fe76a935964a79cb73c8a1a312b068 /media/ffmpeg
parent97bf67f3ea0e4bea0f15a37e487b3bbb511de138 (diff)
downloadchromium_src-3e0fe16bc2c849c91530b0864b944bc5d736f9c7.zip
chromium_src-3e0fe16bc2c849c91530b0864b944bc5d736f9c7.tar.gz
chromium_src-3e0fe16bc2c849c91530b0864b944bc5d736f9c7.tar.bz2
Adding an ALAC enum to AudioDecoderConfig
This CL enables using the ALAC codec within the media pipeline. This does not add ALAC support, as the ALAC codec is not part of the current build. BUG=441343 Review URL: https://codereview.chromium.org/881603002 Cr-Commit-Position: refs/heads/master@{#313654}
Diffstat (limited to 'media/ffmpeg')
-rw-r--r--media/ffmpeg/ffmpeg_common.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/media/ffmpeg/ffmpeg_common.cc b/media/ffmpeg/ffmpeg_common.cc
index 2c99e7e..36d0e79 100644
--- a/media/ffmpeg/ffmpeg_common.cc
+++ b/media/ffmpeg/ffmpeg_common.cc
@@ -92,6 +92,8 @@ static AudioCodec CodecIDToAudioCodec(AVCodecID codec_id) {
return kCodecPCM_MULAW;
case AV_CODEC_ID_OPUS:
return kCodecOpus;
+ case AV_CODEC_ID_ALAC:
+ return kCodecALAC;
default:
DVLOG(1) << "Unknown audio CodecID: " << codec_id;
}
@@ -103,6 +105,8 @@ static AVCodecID AudioCodecToCodecID(AudioCodec audio_codec,
switch (audio_codec) {
case kCodecAAC:
return AV_CODEC_ID_AAC;
+ case kCodecALAC:
+ return AV_CODEC_ID_ALAC;
case kCodecMP3:
return AV_CODEC_ID_MP3;
case kCodecPCM:
@@ -242,6 +246,8 @@ SampleFormat AVSampleFormatToSampleFormat(AVSampleFormat sample_format) {
return kSampleFormatF32;
case AV_SAMPLE_FMT_S16P:
return kSampleFormatPlanarS16;
+ case AV_SAMPLE_FMT_S32P:
+ return kSampleFormatPlanarS32;
case AV_SAMPLE_FMT_FLTP:
return kSampleFormatPlanarF32;
default: