#include "media/filters/gpu_video_accelerator_factories.h"
#include "net/base/net_errors.h"
#include "net/base/net_util.h"
+#include "skia/ext/event_tracer_impl.h"
#include "third_party/WebKit/public/platform/WebString.h"
#include "third_party/WebKit/public/web/WebColorName.h"
#include "third_party/WebKit/public/web/WebDatabase.h"
return RenderThreadImpl::Get()->HostAllocateSharedMemoryBuffer(size);
}
-void EnableWebCoreLogChannels(const std::string& channels) {
+void EnableBlinkPlatformLogChannels(const std::string& channels) {
if (channels.empty())
return;
base::StringTokenizer t(channels, ", ");
audio_message_filter_ = new AudioMessageFilter(GetIOMessageLoopProxy());
AddFilter(audio_message_filter_.get());
- midi_message_filter_ = new MIDIMessageFilter(GetIOMessageLoopProxy());
+ midi_message_filter_ = new MidiMessageFilter(GetIOMessageLoopProxy());
AddFilter(midi_message_filter_.get());
AddFilter((new IndexedDBMessageFilter(thread_safe_sender()))->GetFilter());
GetContentClient()->renderer()->RenderThreadStarted();
+ InitSkiaEventTracer();
+
const CommandLine& command_line = *CommandLine::ForCurrentProcess();
- if (command_line.HasSwitch(switches::kEnableGpuBenchmarking))
+ if (command_line.HasSwitch(cc::switches::kEnableGpuBenchmarking))
RegisterExtension(GpuBenchmarkingExtension::Get());
// Note that under Linux, the media library will normally already have
CompositorOutputSurface::CreateFilter(output_surface_loop.get());
AddFilter(compositor_output_surface_filter_.get());
- WebScriptController::enableV8SingleThreadMode();
-
RenderThreadImpl::RegisterSchemes();
- EnableWebCoreLogChannels(
- command_line.GetSwitchValueASCII(switches::kWebCoreLogChannels));
+ EnableBlinkPlatformLogChannels(
+ command_line.GetSwitchValueASCII(switches::kBlinkPlatformLogChannels));
SetRuntimeFeaturesDefaultsAndUpdateFromArgs(command_line);
scoped_refptr<GpuChannelHost> gpu_channel_host = GetGpuChannel();
const CommandLine* cmd_line = CommandLine::ForCurrentProcess();
scoped_refptr<RendererGpuVideoAcceleratorFactories> gpu_factories;
+ scoped_refptr<base::MessageLoopProxy> media_loop_proxy =
+ GetMediaThreadMessageLoopProxy();
if (!cmd_line->HasSwitch(switches::kDisableAcceleratedVideoDecode)) {
if (!gpu_va_context_provider_ ||
gpu_va_context_provider_->DestroyedOnMainThread()) {
GURL("chrome://gpu/RenderThreadImpl::GetGpuVDAContext3D"),
WebGraphicsContext3DCommandBufferImpl::SharedMemoryLimits())),
"GPU-VideoAccelerator-Offscreen");
+ if (gpu_va_context_provider_) {
+ media_loop_proxy->PostTask(
+ FROM_HERE,
+ base::Bind(
+ base::IgnoreResult(&cc::ContextProvider::BindToCurrentThread),
+ gpu_va_context_provider_));
+ }
}
}
- if (gpu_channel_host) {
+ if (gpu_va_context_provider_) {
gpu_factories = new RendererGpuVideoAcceleratorFactories(
- gpu_channel_host.get(), gpu_va_context_provider_);
+ gpu_channel_host, media_loop_proxy, gpu_va_context_provider_);
}
return gpu_factories;
}