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

Unified Diff: third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp

Issue 2430653002: Mus+Ash: Towards Unifying CompositorFrameSink terminology (Closed)
Patch Set: Updated Created 4 years, 2 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: third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp b/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp
index 472f4cf68af1c37be09eaab36fcea182c9796a80..948b02956d439adbfc501e2932c0246d4d1f8337 100644
--- a/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp
+++ b/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.cpp
@@ -68,7 +68,7 @@ void OffscreenCanvasFrameDispatcherImpl::setTransferableResourceToSharedBitmap(
resource.mailbox_holder.texture_target = 0;
resource.is_software = true;
- // Hold ref to |bitmap|, to keep it alive until the browser ReturnResources.
+ // Hold ref to |bitmap|, to keep it alive until the browser ReclaimResources.
// It guarantees that the shared bitmap is not re-used or deleted.
m_sharedBitmaps.add(m_nextResourceId, std::move(bitmap));
}
@@ -126,7 +126,7 @@ void OffscreenCanvasFrameDispatcherImpl::
resource.is_software = false;
// Hold ref to |textureId| for the piece of GPU memory where the pixel data
- // is uploaded to, to keep it alive until the browser ReturnResources.
+ // is uploaded to, to keep it alive until the browser ReclaimResources.
m_cachedTextureIds.add(m_nextResourceId, textureId);
}
@@ -140,7 +140,7 @@ void OffscreenCanvasFrameDispatcherImpl::
resource.read_lock_fences_enabled = false;
resource.is_software = false;
- // Hold ref to |image|, to keep it alive until the browser ReturnResources.
+ // Hold ref to |image|, to keep it alive until the browser ReclaimResources.
// It guarantees that the resource is not re-used or deleted.
m_cachedImages.add(m_nextResourceId, std::move(image));
}
@@ -311,10 +311,14 @@ void OffscreenCanvasFrameDispatcherImpl::dispatchFrame(
NOTREACHED();
}
- m_sink->SubmitCompositorFrame(std::move(frame), base::Closure());
+ m_sink->SubmitCompositorFrame(std::move(frame));
}
-void OffscreenCanvasFrameDispatcherImpl::ReturnResources(
+void OffscreenCanvasFrameDispatcherImpl::DidReceiveCompositorFrameAck() {
+ // TODO(fsamuel): Implement this.
+}
+
+void OffscreenCanvasFrameDispatcherImpl::ReclaimResources(
const cc::ReturnedResourceArray& resources) {
for (const auto& resource : resources) {
m_cachedImages.remove(resource.id);

Powered by Google App Engine
This is Rietveld 408576698