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

Unified Diff: content/child/child_gpu_memory_buffer_manager.cc

Issue 654223006: Cleanup GpuMemoryBuffer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: style nits Created 6 years, 1 month 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/child/child_gpu_memory_buffer_manager.h ('k') | content/common/child_process_host_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/child/child_gpu_memory_buffer_manager.cc
diff --git a/content/child/child_gpu_memory_buffer_manager.cc b/content/child/child_gpu_memory_buffer_manager.cc
index 9965435923441f0e076efe76ac6d1ca8dd05c1b8..f56c60a5fc7d4054a4a45bfc0f8fd3ccc61fc73e 100644
--- a/content/child/child_gpu_memory_buffer_manager.cc
+++ b/content/child/child_gpu_memory_buffer_manager.cc
@@ -13,10 +13,12 @@ namespace {
void DeletedGpuMemoryBuffer(ThreadSafeSender* sender,
gfx::GpuMemoryBufferType type,
- const gfx::GpuMemoryBufferId& id) {
+ const gfx::GpuMemoryBufferId& id,
+ uint32 sync_point) {
TRACE_EVENT0("renderer",
"ChildGpuMemoryBufferManager::DeletedGpuMemoryBuffer");
- sender->Send(new ChildProcessHostMsg_DeletedGpuMemoryBuffer(type, id));
+ sender->Send(
+ new ChildProcessHostMsg_DeletedGpuMemoryBuffer(type, id, sync_point));
}
} // namespace
@@ -56,7 +58,7 @@ ChildGpuMemoryBufferManager::AllocateGpuMemoryBuffer(
&DeletedGpuMemoryBuffer, sender_, handle.type, handle.global_id)));
if (!buffer) {
sender_->Send(new ChildProcessHostMsg_DeletedGpuMemoryBuffer(
- handle.type, handle.global_id));
+ handle.type, handle.global_id, 0));
return scoped_ptr<gfx::GpuMemoryBuffer>();
}
@@ -69,4 +71,11 @@ ChildGpuMemoryBufferManager::GpuMemoryBufferFromClientBuffer(
return GpuMemoryBufferImpl::FromClientBuffer(buffer);
}
+void ChildGpuMemoryBufferManager::SetDestructionSyncPoint(
+ gfx::GpuMemoryBuffer* buffer,
+ uint32 sync_point) {
+ static_cast<GpuMemoryBufferImpl*>(buffer)
+ ->set_destruction_sync_point(sync_point);
+}
+
} // namespace content
« no previous file with comments | « content/child/child_gpu_memory_buffer_manager.h ('k') | content/common/child_process_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698