diff options
author | tyoshino@chromium.org <tyoshino@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-11 02:34:54 +0000 |
---|---|---|
committer | tyoshino@chromium.org <tyoshino@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-11 02:34:54 +0000 |
commit | 4a46734e12d09c0fa38a2ce706441a25e5d016c0 (patch) | |
tree | 38534d75bd050fcfd8c14055974e76524b3c39d6 /chrome/gpu/gpu_video_decoder.cc | |
parent | 1d124d66343f85bdb54e3cf3fc4ce44ffb2e7cf7 (diff) | |
download | chromium_src-4a46734e12d09c0fa38a2ce706441a25e5d016c0.zip chromium_src-4a46734e12d09c0fa38a2ce706441a25e5d016c0.tar.gz chromium_src-4a46734e12d09c0fa38a2ce706441a25e5d016c0.tar.bz2 |
Revert 77476 - Remove FFmpegVideoDecodeEngine's dependency on AVStream.
This change seems to have caused Linux Heapcheck bot redness.
http://build.chromium.org/p/chromium.memory/builders/Linux%20Heapcheck/builds/4846
First step of many towards removing DemuxerStream::QueryInterface, AVStreamProvider, and MediaFormat.
BUG=28206
TEST=media_unittests
Review URL: http://codereview.chromium.org/6624062
TBR=scherkus@chromium.org
Review URL: http://codereview.chromium.org/6665020
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@77770 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/gpu/gpu_video_decoder.cc')
-rw-r--r-- | chrome/gpu/gpu_video_decoder.cc | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/chrome/gpu/gpu_video_decoder.cc b/chrome/gpu/gpu_video_decoder.cc index 96be0c3..ca72c40 100644 --- a/chrome/gpu/gpu_video_decoder.cc +++ b/chrome/gpu/gpu_video_decoder.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2011 The Chromium Authors. All rights reserved. +// Copyright (c) 2010 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -86,8 +86,7 @@ void GpuVideoDecoder::OnInitializeComplete(const VideoCodecInfo& info) { } // TODO(jiesun): Check the assumption of input size < original size. - param.input_buffer_size = - info.stream_info.surface_width * info.stream_info.surface_height * 3 / 2; + param.input_buffer_size = config_.width * config_.height * 3 / 2; if (!CreateInputTransferBuffer(param.input_buffer_size, ¶m.input_buffer_handle)) { SendInitializeDone(param); @@ -250,6 +249,7 @@ GpuVideoDecoder::GpuVideoDecoder( sender_(sender), renderer_handle_(handle), gles2_decoder_(decoder) { + memset(&config_, 0, sizeof(config_)); memset(&info_, 0, sizeof(info_)); // TODO(jiesun): find a better way to determine which VideoDecodeEngine @@ -272,14 +272,11 @@ GpuVideoDecoder::~GpuVideoDecoder() {} void GpuVideoDecoder::OnInitialize(const GpuVideoDecoderInitParam& param) { // TODO(jiesun): codec id should come from |param|. - media::VideoCodecConfig config(media::kCodecH264, - param.width, - param.height, - param.frame_rate_num, - param.frame_rate_den, - NULL, - 0); - decode_engine_->Initialize(message_loop_, this, this, config); + config_.codec = media::kCodecH264; + config_.width = param.width; + config_.height = param.height; + config_.opaque_context = NULL; + decode_engine_->Initialize(message_loop_, this, this, config_); } void GpuVideoDecoder::OnUninitialize() { |