diff options
author | backer@chromium.org <backer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-13 17:18:11 +0000 |
---|---|---|
committer | backer@chromium.org <backer@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-10-13 17:18:11 +0000 |
commit | 839d517e126e4f0d09113f26533d974c55b6ce19 (patch) | |
tree | 79087ca7c18ad743e9adb4ab2117cc60cdbb05a2 /content/browser | |
parent | b218144ac084930854ba153376e86318fb1be99f (diff) | |
download | chromium_src-839d517e126e4f0d09113f26533d974c55b6ce19.zip chromium_src-839d517e126e4f0d09113f26533d974c55b6ce19.tar.gz chromium_src-839d517e126e4f0d09113f26533d974c55b6ce19.tar.bz2 |
Enable accelerated WebKit compositor for Aura.
This allows the use of the WebKit compositor for Aura on Linux. It reuses the same display path as TOUCH_UI.
BUG=none
TEST=build GYP_DEFINES="use_aura" on Linux; go to http://www.webkit.org/blog-files/3d-transforms/poster-circle.html
Review URL: http://codereview.chromium.org/8241012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@105323 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser')
-rw-r--r-- | content/browser/gpu/gpu_process_host_ui_shim.cc | 14 | ||||
-rw-r--r-- | content/browser/gpu/gpu_process_host_ui_shim.h | 9 | ||||
-rw-r--r-- | content/browser/renderer_host/render_widget_host_view.h | 2 |
3 files changed, 13 insertions, 12 deletions
diff --git a/content/browser/gpu/gpu_process_host_ui_shim.cc b/content/browser/gpu/gpu_process_host_ui_shim.cc index 9f0b77c..df939bac 100644 --- a/content/browser/gpu/gpu_process_host_ui_shim.cc +++ b/content/browser/gpu/gpu_process_host_ui_shim.cc @@ -145,7 +145,7 @@ bool GpuProcessHostUIShim::OnMessageReceived(const IPC::Message& message) { return OnControlMessageReceived(message); } -#if defined(OS_MACOSX) || defined(TOUCH_UI) +#if defined(OS_MACOSX) || defined(UI_COMPOSITOR_IMAGE_TRANSPORT) void GpuProcessHostUIShim::SendToGpuHost(int host_id, IPC::Message* msg) { GpuProcessHostUIShim* ui_shim = FromID(host_id); @@ -175,14 +175,14 @@ bool GpuProcessHostUIShim::OnControlMessageReceived( IPC_MESSAGE_HANDLER(GpuHostMsg_ResizeView, OnResizeView) #endif -#if defined(OS_MACOSX) || defined(TOUCH_UI) +#if defined(OS_MACOSX) || defined(UI_COMPOSITOR_IMAGE_TRANSPORT) IPC_MESSAGE_HANDLER(GpuHostMsg_AcceleratedSurfaceBuffersSwapped, OnAcceleratedSurfaceBuffersSwapped) IPC_MESSAGE_HANDLER(GpuHostMsg_AcceleratedSurfaceNew, OnAcceleratedSurfaceNew) #endif -#if defined(TOUCH_UI) +#if defined(UI_COMPOSITOR_IMAGE_TRANSPORT) IPC_MESSAGE_HANDLER(GpuHostMsg_AcceleratedSurfaceRelease, OnAcceleratedSurfaceRelease) #endif @@ -253,7 +253,7 @@ void GpuProcessHostUIShim::OnResizeView(int32 renderer_id, #endif -#if defined(OS_MACOSX) || defined(TOUCH_UI) +#if defined(OS_MACOSX) || defined(UI_COMPOSITOR_IMAGE_TRANSPORT) void GpuProcessHostUIShim::OnAcceleratedSurfaceNew( const GpuHostMsg_AcceleratedSurfaceNew_Params& params) { @@ -303,7 +303,7 @@ void GpuProcessHostUIShim::OnAcceleratedSurfaceNew( params.height, surface_id); } -#elif defined(TOUCH_UI) +#else // defined(UI_COMPOSITOR_IMAGE_TRANSPORT) view->AcceleratedSurfaceNew( params.width, params.height, &surface_id, &surface_handle); #endif @@ -341,7 +341,7 @@ void GpuProcessHostUIShim::OnAcceleratedSurfaceBuffersSwapped( params.renderer_id, params.route_id, host_id_); -#elif defined(TOUCH_UI) +#else // defined(UI_COMPOSITOR_IMAGE_TRANSPORT) // view must send ACK message after next composite view->AcceleratedSurfaceBuffersSwapped( params.surface_id, params.route_id, host_id_); @@ -350,7 +350,7 @@ void GpuProcessHostUIShim::OnAcceleratedSurfaceBuffersSwapped( #endif -#if defined(TOUCH_UI) +#if defined(UI_COMPOSITOR_IMAGE_TRANSPORT) void GpuProcessHostUIShim::OnAcceleratedSurfaceRelease( const GpuHostMsg_AcceleratedSurfaceRelease_Params& params) { diff --git a/content/browser/gpu/gpu_process_host_ui_shim.h b/content/browser/gpu/gpu_process_host_ui_shim.h index 92bff71..5acac4ac 100644 --- a/content/browser/gpu/gpu_process_host_ui_shim.h +++ b/content/browser/gpu/gpu_process_host_ui_shim.h @@ -76,7 +76,7 @@ class GpuProcessHostUIShim // actually received on the IO thread. virtual bool OnMessageReceived(const IPC::Message& message); -#if defined(OS_MACOSX) || defined(TOUCH_UI) +#if defined(OS_MACOSX) || defined(UI_COMPOSITOR_IMAGE_TRANSPORT) // TODO(apatrick): Remove this when mac does not use AcceleratedSurfaces for // when running the GPU thread in the browser process. // This is now also used in TOUCH_UI builds. @@ -92,21 +92,22 @@ class GpuProcessHostUIShim void OnLogMessage(int level, const std::string& header, const std::string& message); -#if defined(TOOLKIT_USES_GTK) && !defined(TOUCH_UI) || defined(OS_WIN) +#if defined(TOOLKIT_USES_GTK) && !defined(UI_COMPOSITOR_IMAGE_TRANSPORT) || \ + defined(OS_WIN) void OnResizeView(int32 renderer_id, int32 render_view_id, int32 command_buffer_route_id, gfx::Size size); #endif -#if defined(OS_MACOSX) || defined(TOUCH_UI) +#if defined(OS_MACOSX) || defined(UI_COMPOSITOR_IMAGE_TRANSPORT) void OnAcceleratedSurfaceNew( const GpuHostMsg_AcceleratedSurfaceNew_Params& params); void OnAcceleratedSurfaceBuffersSwapped( const GpuHostMsg_AcceleratedSurfaceBuffersSwapped_Params& params); #endif -#if defined(TOUCH_UI) +#if defined(UI_COMPOSITOR_IMAGE_TRANSPORT) void OnAcceleratedSurfaceRelease( const GpuHostMsg_AcceleratedSurfaceRelease_Params& params); #endif diff --git a/content/browser/renderer_host/render_widget_host_view.h b/content/browser/renderer_host/render_widget_host_view.h index 7ac8290..a3ccb37 100644 --- a/content/browser/renderer_host/render_widget_host_view.h +++ b/content/browser/renderer_host/render_widget_host_view.h @@ -256,7 +256,7 @@ class RenderWidgetHostView { virtual void GpuRenderingStateDidChange() = 0; #endif -#if defined(TOUCH_UI) +#if defined(UI_COMPOSITOR_IMAGE_TRANSPORT) virtual void AcceleratedSurfaceNew( int32 width, int32 height, |