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

Side by Side Diff: media/test/pipeline_integration_test_base.cc

Issue 1273943002: media: Make GpuMemoryBuffers VideoFrame copies asynchronous. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address reveman's and dalecurtis' comments. Disable GMB VideoFrames. Created 5 years, 4 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/test/pipeline_integration_test_base.h" 5 #include "media/test/pipeline_integration_test_base.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/memory/scoped_vector.h" 8 #include "base/memory/scoped_vector.h"
9 #include "media/base/cdm_context.h" 9 #include "media/base/cdm_context.h"
10 #include "media/base/media_log.h" 10 #include "media/base/media_log.h"
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 242
243 // Simulate a 60Hz rendering sink. 243 // Simulate a 60Hz rendering sink.
244 video_sink_.reset(new NullVideoSink( 244 video_sink_.reset(new NullVideoSink(
245 clockless_playback_, base::TimeDelta::FromSecondsD(1.0 / 60), 245 clockless_playback_, base::TimeDelta::FromSecondsD(1.0 / 60),
246 base::Bind(&PipelineIntegrationTestBase::OnVideoFramePaint, 246 base::Bind(&PipelineIntegrationTestBase::OnVideoFramePaint,
247 base::Unretained(this)), 247 base::Unretained(this)),
248 message_loop_.task_runner())); 248 message_loop_.task_runner()));
249 249
250 // Disable frame dropping if hashing is enabled. 250 // Disable frame dropping if hashing is enabled.
251 scoped_ptr<VideoRenderer> video_renderer(new VideoRendererImpl( 251 scoped_ptr<VideoRenderer> video_renderer(new VideoRendererImpl(
252 message_loop_.task_runner(), video_sink_.get(), 252 message_loop_.task_runner(), message_loop_.task_runner().get(),
253 video_decoders.Pass(), false, nullptr, new MediaLog())); 253 video_sink_.get(), video_decoders.Pass(), false, nullptr,
254 new MediaLog()));
254 255
255 if (!clockless_playback_) { 256 if (!clockless_playback_) {
256 audio_sink_ = new NullAudioSink(message_loop_.task_runner()); 257 audio_sink_ = new NullAudioSink(message_loop_.task_runner());
257 } else { 258 } else {
258 clockless_audio_sink_ = new ClocklessAudioSink(); 259 clockless_audio_sink_ = new ClocklessAudioSink();
259 } 260 }
260 261
261 ScopedVector<AudioDecoder> audio_decoders; 262 ScopedVector<AudioDecoder> audio_decoders;
262 263
263 #if !defined(MEDIA_DISABLE_FFMPEG) 264 #if !defined(MEDIA_DISABLE_FFMPEG)
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 DCHECK(clockless_playback_); 337 DCHECK(clockless_playback_);
337 return clockless_audio_sink_->render_time(); 338 return clockless_audio_sink_->render_time();
338 } 339 }
339 340
340 base::TimeTicks DummyTickClock::NowTicks() { 341 base::TimeTicks DummyTickClock::NowTicks() {
341 now_ += base::TimeDelta::FromSeconds(60); 342 now_ += base::TimeDelta::FromSeconds(60);
342 return now_; 343 return now_;
343 } 344 }
344 345
345 } // namespace media 346 } // namespace media
OLDNEW
« no previous file with comments | « media/renderers/video_renderer_impl_unittest.cc ('k') | media/video/gpu_memory_buffer_video_frame_pool.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698