Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1267)

Unified Diff: media/filters/vpx_video_decoder.cc

Issue 189123003: Remove deprecated media switches. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed. Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/filters/stream_parser_factory.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/vpx_video_decoder.cc
diff --git a/media/filters/vpx_video_decoder.cc b/media/filters/vpx_video_decoder.cc
index b20d891b198930df50737700d8d5d2bb3350e0ae..df314ec2c1e10dab43b8ff17a886b5f8ca71d620 100644
--- a/media/filters/vpx_video_decoder.cc
+++ b/media/filters/vpx_video_decoder.cc
@@ -259,15 +259,11 @@ static vpx_codec_ctx* InitializeVpxContext(vpx_codec_ctx* context,
}
bool VpxVideoDecoder::ConfigureDecoder(const VideoDecoderConfig& config) {
- const CommandLine* cmd_line = CommandLine::ForCurrentProcess();
- bool can_handle = false;
- if (config.codec() == kCodecVP9)
- can_handle = true;
- if (!cmd_line->HasSwitch(switches::kDisableVp8AlphaPlayback) &&
- config.codec() == kCodecVP8 && config.format() == VideoFrame::YV12A) {
- can_handle = true;
- }
- if (!can_handle)
+ if (config.codec() != kCodecVP8 && config.codec() != kCodecVP9)
+ return false;
+ // Only VP8 videos with alpha are handled by VpxVideoDecoder. Everything else
+ // goes to FFmpegVideoDecoder.
+ if (config.codec() == kCodecVP8 && config.format() != VideoFrame::YV12A)
return false;
CloseDecoder();
« no previous file with comments | « media/filters/stream_parser_factory.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698