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

Unified Diff: content/renderer/media/media_stream_dependency_factory.cc

Issue 19534002: Make RendererGpuVideoDecoderFactories live on arbitrary threads. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address review comments Created 7 years, 5 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
Index: content/renderer/media/media_stream_dependency_factory.cc
diff --git a/content/renderer/media/media_stream_dependency_factory.cc b/content/renderer/media/media_stream_dependency_factory.cc
index f15f1036fbd1830f86fdd17e2544e55cc306aff6..b32348fc774217b4e9c64a89578bf7275b644e19 100644
--- a/content/renderer/media/media_stream_dependency_factory.cc
+++ b/content/renderer/media/media_stream_dependency_factory.cc
@@ -497,10 +497,14 @@ bool MediaStreamDependencyFactory::CreatePeerConnectionFactory() {
const CommandLine* cmd_line = CommandLine::ForCurrentProcess();
if (cmd_line->HasSwitch(switches::kEnableWebRtcHWDecoding)) {
+ scoped_refptr<base::MessageLoopProxy> media_loop_proxy =
+ RenderThreadImpl::current()->GetMediaThreadMessageLoopProxy();
scoped_refptr<media::GpuVideoDecoder::Factories> gpu_factories =
- RenderThreadImpl::current()->GetGpuFactories();
- if (gpu_factories.get() != NULL)
- decoder_factory.reset(new RTCVideoDecoderFactory(gpu_factories));
+ RenderThreadImpl::current()->GetGpuFactories(media_loop_proxy);
+ if (gpu_factories.get() != NULL) {
+ decoder_factory.reset(
+ new RTCVideoDecoderFactory(media_loop_proxy, gpu_factories));
+ }
}
#if defined(GOOGLE_TV)
// PeerConnectionFactory will hold the ownership of this

Powered by Google App Engine
This is Rietveld 408576698