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

Unified Diff: content/browser/gpu/browser_gpu_channel_host_factory.h

Issue 302603004: Plumb GpuMemoryBuffer allocation to GPU process. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 7 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/browser/gpu/browser_gpu_channel_host_factory.h
diff --git a/content/browser/gpu/browser_gpu_channel_host_factory.h b/content/browser/gpu/browser_gpu_channel_host_factory.h
index c2637f033cc3ca00ce518c353f8c9e901037f68e..5d1e129669a5e142bd9cfaacce3d0574816ce0a8 100644
--- a/content/browser/gpu/browser_gpu_channel_host_factory.h
+++ b/content/browser/gpu/browser_gpu_channel_host_factory.h
@@ -41,6 +41,9 @@ class CONTENT_EXPORT BrowserGpuChannelHostFactory
size_t height,
unsigned internalformat,
unsigned usage) OVERRIDE;
+ virtual void AllocateGpuMemoryBufferAsync(
reveman 2014/05/27 22:46:01 I'd like to have this replace Create/DeleteImage.
alexst (slow to review) 2014/05/28 14:18:57 I was planning to add the new way first and then r
reveman 2014/05/28 16:42:26 Removing Create/DeleteImage in follow up patches i
+ const gfx::GpuMemoryBufferParams& params,
reveman 2014/05/27 22:46:01 The idea I had for this IPC was that it would take
alexst (slow to review) 2014/05/28 14:18:57 Got it.
+ const AllocateGpuMemoryBufferCallback& callback) OVERRIDE;
// Specify a task runner and callback to be used for a set of messages. The
// callback will be set up on the current GpuProcessHost, identified by
@@ -86,6 +89,16 @@ class CONTENT_EXPORT BrowserGpuChannelHostFactory
static void AddFilterOnIO(int gpu_host_id,
scoped_refptr<IPC::MessageFilter> filter);
+ void AllocateGpuMemoryBufferAsyncOnIO(
+ const gfx::GpuMemoryBufferParams& params,
+ const AllocateGpuMemoryBufferCallback& callback);
+ static void GpuMemoryBufferAllocatedAsyncOnIO(
+ const AllocateGpuMemoryBufferCallback&,
+ const gfx::GpuMemoryBufferHandle& handle);
+ static void GpuMemoryBufferAllocatedAsync(
+ const AllocateGpuMemoryBufferCallback&,
+ const gfx::GpuMemoryBufferHandle& handle);
+
const int gpu_client_id_;
scoped_ptr<base::WaitableEvent> shutdown_event_;
scoped_refptr<GpuChannelHost> gpu_channel_;

Powered by Google App Engine
This is Rietveld 408576698