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

Unified Diff: content/browser/gpu/browser_gpu_memory_buffer_manager.cc

Issue 1414793018: Revert of Converted video frame and image callbacks to use new sync tokens. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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/browser/gpu/browser_gpu_memory_buffer_manager.h ('k') | content/browser/gpu/gpu_process_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/gpu/browser_gpu_memory_buffer_manager.cc
diff --git a/content/browser/gpu/browser_gpu_memory_buffer_manager.cc b/content/browser/gpu/browser_gpu_memory_buffer_manager.cc
index d7bb0344997f9c9d3bfbbdd297251e279a42cfbc..189f0c5e57d08092a06d0cdbb9e705a285012e94 100644
--- a/content/browser/gpu/browser_gpu_memory_buffer_manager.cc
+++ b/content/browser/gpu/browser_gpu_memory_buffer_manager.cc
@@ -67,9 +67,9 @@
void GpuMemoryBufferDeleted(
scoped_refptr<base::SingleThreadTaskRunner> destruction_task_runner,
const GpuMemoryBufferImpl::DestructionCallback& destruction_callback,
- const gpu::SyncToken& sync_token) {
+ uint32 sync_point) {
destruction_task_runner->PostTask(
- FROM_HERE, base::Bind(destruction_callback, sync_token));
+ FROM_HERE, base::Bind(destruction_callback, sync_point));
}
bool IsNativeGpuMemoryBufferFactoryConfigurationSupported(
@@ -341,11 +341,11 @@
return GpuMemoryBufferImpl::FromClientBuffer(buffer);
}
-void BrowserGpuMemoryBufferManager::SetDestructionSyncToken(
+void BrowserGpuMemoryBufferManager::SetDestructionSyncPoint(
gfx::GpuMemoryBuffer* buffer,
- const gpu::SyncToken& sync_token) {
+ uint32 sync_point) {
static_cast<GpuMemoryBufferImpl*>(buffer)
- ->set_destruction_sync_token(sync_token);
+ ->set_destruction_sync_point(sync_point);
}
bool BrowserGpuMemoryBufferManager::OnMemoryDump(
@@ -394,10 +394,10 @@
gfx::GpuMemoryBufferId id,
base::ProcessHandle child_process_handle,
int child_client_id,
- const gpu::SyncToken& sync_token) {
- DCHECK_CURRENTLY_ON(BrowserThread::IO);
-
- DestroyGpuMemoryBufferOnIO(id, child_client_id, sync_token);
+ uint32 sync_point) {
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
+
+ DestroyGpuMemoryBufferOnIO(id, child_client_id, sync_point);
}
void BrowserGpuMemoryBufferManager::ProcessRemoved(
@@ -418,7 +418,7 @@
GpuProcessHost* host = GpuProcessHost::FromID(buffer.second.gpu_host_id);
if (host)
- host->DestroyGpuMemoryBuffer(buffer.first, client_id, gpu::SyncToken());
+ host->DestroyGpuMemoryBuffer(buffer.first, client_id, 0);
}
clients_.erase(client_it);
@@ -653,7 +653,7 @@
if (!handle.is_null()) {
GpuProcessHost* host = GpuProcessHost::FromID(gpu_host_id);
if (host)
- host->DestroyGpuMemoryBuffer(handle.id, client_id, gpu::SyncToken());
+ host->DestroyGpuMemoryBuffer(handle.id, client_id, 0);
}
callback.Run(gfx::GpuMemoryBufferHandle());
return;
@@ -705,7 +705,7 @@
void BrowserGpuMemoryBufferManager::DestroyGpuMemoryBufferOnIO(
gfx::GpuMemoryBufferId id,
int client_id,
- const gpu::SyncToken& sync_token) {
+ uint32 sync_point) {
DCHECK_CURRENTLY_ON(BrowserThread::IO);
DCHECK(clients_.find(client_id) != clients_.end());
@@ -726,7 +726,7 @@
GpuProcessHost* host = GpuProcessHost::FromID(buffer_it->second.gpu_host_id);
if (host)
- host->DestroyGpuMemoryBuffer(id, client_id, sync_token);
+ host->DestroyGpuMemoryBuffer(id, client_id, sync_point);
buffers.erase(buffer_it);
}
« no previous file with comments | « content/browser/gpu/browser_gpu_memory_buffer_manager.h ('k') | content/browser/gpu/gpu_process_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698