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

Unified Diff: content/renderer/pepper/video_decoder_shim.cc

Issue 1485043002: Passed is_encrypted parameter to the VDA initialization. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Deleted erroneously added files Created 5 years, 1 month 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
Index: content/renderer/pepper/video_decoder_shim.cc
diff --git a/content/renderer/pepper/video_decoder_shim.cc b/content/renderer/pepper/video_decoder_shim.cc
index 84dd33a4f367b527692cb90a09c12b92d4dbc5c2..67fd0796b04fe948860578e7764a91ff7fefbdd9 100644
--- a/content/renderer/pepper/video_decoder_shim.cc
+++ b/content/renderer/pepper/video_decoder_shim.cc
@@ -869,17 +869,17 @@ VideoDecoderShim::~VideoDecoderShim() {
}
bool VideoDecoderShim::Initialize(
- media::VideoCodecProfile profile,
+ const media::VideoDecodeAccelerator::InitParams& params,
media::VideoDecodeAccelerator::Client* client) {
DCHECK_EQ(client, host_);
DCHECK(RenderThreadImpl::current());
DCHECK_EQ(state_, UNINITIALIZED);
media::VideoCodec codec = media::kUnknownVideoCodec;
- if (profile <= media::H264PROFILE_MAX)
+ if (params.profile <= media::H264PROFILE_MAX)
codec = media::kCodecH264;
- else if (profile <= media::VP8PROFILE_MAX)
+ else if (params.profile <= media::VP8PROFILE_MAX)
codec = media::kCodecVP8;
- else if (profile <= media::VP9PROFILE_MAX)
+ else if (params.profile <= media::VP9PROFILE_MAX)
codec = media::kCodecVP9;
DCHECK_NE(codec, media::kUnknownVideoCodec);
@@ -890,7 +890,8 @@ bool VideoDecoderShim::Initialize(
return false;
media::VideoDecoderConfig config(
- codec, profile, media::PIXEL_FORMAT_YV12, media::COLOR_SPACE_UNSPECIFIED,
+ codec, params.profile, media::PIXEL_FORMAT_YV12,
+ media::COLOR_SPACE_UNSPECIFIED,
gfx::Size(32, 24), // Small sizes that won't fail.
gfx::Rect(32, 24), gfx::Size(32, 24),
// TODO(bbudge): Verify extra data isn't needed.

Powered by Google App Engine
This is Rietveld 408576698