diff options
author | phajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-23 22:28:01 +0000 |
---|---|---|
committer | phajdan.jr@chromium.org <phajdan.jr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-23 22:28:01 +0000 |
commit | 219013189f216b2b287b91a3c59ff0dcc1c42cda (patch) | |
tree | a843340248dc0202bb0a7ff9f215d7ad49b53932 /media | |
parent | a608d17f9338dc10159d50f81a9f64fcd51c9c80 (diff) | |
download | chromium_src-219013189f216b2b287b91a3c59ff0dcc1c42cda.zip chromium_src-219013189f216b2b287b91a3c59ff0dcc1c42cda.tar.gz chromium_src-219013189f216b2b287b91a3c59ff0dcc1c42cda.tar.bz2 |
media: use AVCodecID instead of deprecated CodecID
BUG=none
Review URL: https://codereview.chromium.org/13858004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@195923 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media')
-rw-r--r-- | media/ffmpeg/ffmpeg_common.cc | 10 | ||||
-rw-r--r-- | media/ffmpeg/ffmpeg_common.h | 4 | ||||
-rw-r--r-- | media/filters/ffmpeg_video_decoder.cc | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/media/ffmpeg/ffmpeg_common.cc b/media/ffmpeg/ffmpeg_common.cc index cc7dfc2..bd0ed2e 100644 --- a/media/ffmpeg/ffmpeg_common.cc +++ b/media/ffmpeg/ffmpeg_common.cc @@ -57,7 +57,7 @@ int64 ConvertToTimeBase(const AVRational& time_base, return av_rescale_q(timestamp.InMicroseconds(), kMicrosBase, time_base); } -AudioCodec CodecIDToAudioCodec(CodecID codec_id) { +AudioCodec CodecIDToAudioCodec(AVCodecID codec_id) { switch (codec_id) { case AV_CODEC_ID_AAC: return kCodecAAC; @@ -94,8 +94,8 @@ AudioCodec CodecIDToAudioCodec(CodecID codec_id) { return kUnknownAudioCodec; } -static CodecID AudioCodecToCodecID(AudioCodec audio_codec, - SampleFormat sample_format) { +static AVCodecID AudioCodecToCodecID(AudioCodec audio_codec, + SampleFormat sample_format) { switch (audio_codec) { case kCodecAAC: return AV_CODEC_ID_AAC; @@ -141,7 +141,7 @@ static CodecID AudioCodecToCodecID(AudioCodec audio_codec, return AV_CODEC_ID_NONE; } -VideoCodec CodecIDToVideoCodec(CodecID codec_id) { +VideoCodec CodecIDToVideoCodec(AVCodecID codec_id) { switch (codec_id) { case AV_CODEC_ID_H264: return kCodecH264; @@ -161,7 +161,7 @@ VideoCodec CodecIDToVideoCodec(CodecID codec_id) { return kUnknownVideoCodec; } -static CodecID VideoCodecToCodecID(VideoCodec video_codec) { +static AVCodecID VideoCodecToCodecID(VideoCodec video_codec) { switch (video_codec) { case kCodecH264: return AV_CODEC_ID_H264; diff --git a/media/ffmpeg/ffmpeg_common.h b/media/ffmpeg/ffmpeg_common.h index 62c6385..6cb7862 100644 --- a/media/ffmpeg/ffmpeg_common.h +++ b/media/ffmpeg/ffmpeg_common.h @@ -99,10 +99,10 @@ VideoFrame::Format PixelFormatToVideoFormat(PixelFormat pixel_format); PixelFormat VideoFormatToPixelFormat(VideoFrame::Format video_format); // Converts an FFmpeg video codec ID into its corresponding supported codec id. -VideoCodec CodecIDToVideoCodec(CodecID codec_id); +VideoCodec CodecIDToVideoCodec(AVCodecID codec_id); // Converts an FFmpeg audio codec ID into its corresponding supported codec id. -AudioCodec CodecIDToAudioCodec(CodecID codec_id); +AudioCodec CodecIDToAudioCodec(AVCodecID codec_id); } // namespace media diff --git a/media/filters/ffmpeg_video_decoder.cc b/media/filters/ffmpeg_video_decoder.cc index 105199f..b3bc247 100644 --- a/media/filters/ffmpeg_video_decoder.cc +++ b/media/filters/ffmpeg_video_decoder.cc @@ -41,7 +41,7 @@ static const int kMaxDecodeThreads = 16; // Returns the number of threads given the FFmpeg CodecID. Also inspects the // command line for a valid --video-threads flag. -static int GetThreadCount(CodecID codec_id) { +static int GetThreadCount(AVCodecID codec_id) { // Refer to http://crbug.com/93932 for tsan suppressions on decoding. int decode_threads = kDecodeThreads; |