diff options
author | jbauman@chromium.org <jbauman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-22 23:05:57 +0000 |
---|---|---|
committer | jbauman@chromium.org <jbauman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-22 23:05:57 +0000 |
commit | a7f3568e1e8421fd6a489a87894e779eeec03dfa (patch) | |
tree | 4d1f5d044121edb0d264db1c29dee4a6fc840eba /content | |
parent | e936b9ef160643c4272f44562ef743cfe01c1854 (diff) | |
download | chromium_src-a7f3568e1e8421fd6a489a87894e779eeec03dfa.zip chromium_src-a7f3568e1e8421fd6a489a87894e779eeec03dfa.tar.gz chromium_src-a7f3568e1e8421fd6a489a87894e779eeec03dfa.tar.bz2 |
Add delegated rendering support for software renderer.
This patch adds support to cc/ for delegated rendering with a software compositor. A new SharedBitmapManager is added, which will create SharedBitmaps with unique IDs in shared memory. These can be filled in the child, and their IDs can be sent to the browser so it can map them and draw from them.
No implementations of the SharedBitmapManager are added in this patch, so delegated rendering support won't work in practice yet, and it will fall back to not allocating anything in shared memory.
BUG=
Review URL: https://codereview.chromium.org/24632004
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@230245 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r-- | content/browser/renderer_host/compositor_impl_android.cc | 3 | ||||
-rw-r--r-- | content/common/cc_messages.h | 1 | ||||
-rw-r--r-- | content/renderer/gpu/render_widget_compositor.cc | 5 | ||||
-rw-r--r-- | content/test/web_layer_tree_view_impl_for_testing.cc | 2 |
4 files changed, 6 insertions, 5 deletions
diff --git a/content/browser/renderer_host/compositor_impl_android.cc b/content/browser/renderer_host/compositor_impl_android.cc index da0c00f..fcf8479 100644 --- a/content/browser/renderer_host/compositor_impl_android.cc +++ b/content/browser/renderer_host/compositor_impl_android.cc @@ -229,7 +229,8 @@ void CompositorImpl::SetVisible(bool visible) { g_impl_thread ? g_impl_thread->message_loop()->message_loop_proxy() : NULL; - host_ = cc::LayerTreeHost::Create(this, settings, impl_thread_task_runner); + host_ = cc::LayerTreeHost::Create( + this, NULL, settings, impl_thread_task_runner); host_->SetRootLayer(root_layer_); host_->SetVisible(true); diff --git a/content/common/cc_messages.h b/content/common/cc_messages.h index b1271b3..7fee1e0 100644 --- a/content/common/cc_messages.h +++ b/content/common/cc_messages.h @@ -222,6 +222,7 @@ IPC_STRUCT_TRAITS_BEGIN(cc::TransferableResource) IPC_STRUCT_TRAITS_MEMBER(filter) IPC_STRUCT_TRAITS_MEMBER(size) IPC_STRUCT_TRAITS_MEMBER(mailbox) + IPC_STRUCT_TRAITS_MEMBER(is_software) IPC_STRUCT_TRAITS_END() IPC_STRUCT_TRAITS_BEGIN(cc::ReturnedResource) diff --git a/content/renderer/gpu/render_widget_compositor.cc b/content/renderer/gpu/render_widget_compositor.cc index d9ebdcb..42c0eb6 100644 --- a/content/renderer/gpu/render_widget_compositor.cc +++ b/content/renderer/gpu/render_widget_compositor.cc @@ -412,9 +412,8 @@ bool RenderWidgetCompositor::ScheduleMicroBenchmark( bool RenderWidgetCompositor::initialize(cc::LayerTreeSettings settings) { scoped_refptr<base::MessageLoopProxy> compositor_message_loop_proxy = RenderThreadImpl::current()->compositor_message_loop_proxy(); - layer_tree_host_ = cc::LayerTreeHost::Create(this, - settings, - compositor_message_loop_proxy); + layer_tree_host_ = cc::LayerTreeHost::Create( + this, NULL, settings, compositor_message_loop_proxy); return layer_tree_host_; } diff --git a/content/test/web_layer_tree_view_impl_for_testing.cc b/content/test/web_layer_tree_view_impl_for_testing.cc index 1bf4ee5..4fe5c21 100644 --- a/content/test/web_layer_tree_view_impl_for_testing.cc +++ b/content/test/web_layer_tree_view_impl_for_testing.cc @@ -44,7 +44,7 @@ bool WebLayerTreeViewImplForTesting::Initialize() { // Accelerated animations are enabled for unit tests. settings.accelerated_animation_enabled = true; - layer_tree_host_ = cc::LayerTreeHost::Create(this, settings, NULL); + layer_tree_host_ = cc::LayerTreeHost::Create(this, NULL, settings, NULL); if (!layer_tree_host_) return false; return true; |