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

Unified Diff: content/renderer/render_thread_impl.cc

Issue 10798006: Implement WebCompositorOutputSurface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more fixes Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/renderer/render_thread_impl.h ('k') | content/renderer/render_view_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/render_thread_impl.cc
diff --git a/content/renderer/render_thread_impl.cc b/content/renderer/render_thread_impl.cc
index 35ab4ecd08337a77dcb129615ca53d7817e2c77d..0fa3da827c35376f566ba7a9c1679e136f4966a7 100644
--- a/content/renderer/render_thread_impl.cc
+++ b/content/renderer/render_thread_impl.cc
@@ -56,6 +56,7 @@
#include "content/renderer/dom_storage/webstoragearea_impl.h"
#include "content/renderer/dom_storage/webstoragenamespace_impl.h"
#include "content/renderer/gpu/compositor_thread.h"
+#include "content/renderer/gpu/compositor_output_surface.h"
#include "content/renderer/gpu/gpu_benchmarking_extension.h"
#include "content/renderer/media/audio_hardware.h"
#include "content/renderer/media/audio_input_message_filter.h"
@@ -70,6 +71,7 @@
#include "content/renderer/renderer_webkitplatformsupport_impl.h"
#include "grit/content_resources.h"
#include "ipc/ipc_channel_handle.h"
+#include "ipc/ipc_forwarding_message_filter.h"
#include "ipc/ipc_platform_file.h"
#include "media/base/media.h"
#include "net/base/net_errors.h"
@@ -299,6 +301,9 @@ RenderThreadImpl::~RenderThreadImpl() {
if (file_thread_.get())
file_thread_->Stop();
+ RemoveFilter(compositor_output_surface_filter_.get());
+ compositor_output_surface_filter_ = NULL;
+
if (compositor_initialized_) {
WebKit::WebCompositor::shutdown();
compositor_initialized_ = false;
@@ -506,6 +511,14 @@ void RenderThreadImpl::EnsureWebKitInitialized() {
}
compositor_initialized_ = true;
+ MessageLoop* output_surface_loop = enable ?
+ compositor_thread_->message_loop() :
+ MessageLoop::current();
+
+ compositor_output_surface_filter_ = CompositorOutputSurface::CreateFilter(
+ output_surface_loop->message_loop_proxy());
+ AddFilter(compositor_output_surface_filter_.get());
+
WebScriptController::enableV8SingleThreadMode();
RenderThreadImpl::RegisterSchemes();
« no previous file with comments | « content/renderer/render_thread_impl.h ('k') | content/renderer/render_view_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698