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

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

Issue 2594843002: Implementing promise-based commit for driving OffscreenCanvas animations (Closed)
Patch Set: rebase Created 3 years, 11 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.h
diff --git a/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.h b/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.h
index bb531ca2d5198708d18e204033fe97105ff750e0..6f10cc7993f666a5d33f9ccb9a6ea3e798b8d238 100644
--- a/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.h
+++ b/third_party/WebKit/Source/platform/graphics/OffscreenCanvasFrameDispatcherImpl.h
@@ -23,24 +23,26 @@ class PLATFORM_EXPORT OffscreenCanvasFrameDispatcherImpl final
NON_EXPORTED_BASE(
public cc::mojom::blink::MojoCompositorFrameSinkClient) {
public:
- OffscreenCanvasFrameDispatcherImpl(uint32_t clientId,
+ OffscreenCanvasFrameDispatcherImpl(OffscreenCanvasFrameDispatcherClient*,
+ uint32_t clientId,
uint32_t sinkId,
int canvasId,
int width,
int height);
// OffscreenCanvasFrameDispatcher implementation.
- ~OffscreenCanvasFrameDispatcherImpl() override {}
+ ~OffscreenCanvasFrameDispatcherImpl() final;
void dispatchFrame(RefPtr<StaticBitmapImage>,
double commitStartTime,
- bool isWebGLSoftwareRendering = false) override;
- void reclaimResource(unsigned resourceId) override;
+ bool isWebGLSoftwareRendering = false) final;
+ void reclaimResource(unsigned resourceId) final;
+ void reshape(int width, int height) final;
// cc::mojom::blink::MojoCompositorFrameSinkClient implementation.
- void DidReceiveCompositorFrameAck() override;
- void OnBeginFrame(const cc::BeginFrameArgs&) override;
- void ReclaimResources(const cc::ReturnedResourceArray& resources) override;
- void WillDrawSurface() override;
+ void DidReceiveCompositorFrameAck() final;
+ void OnBeginFrame(const cc::BeginFrameArgs&) final;
+ void ReclaimResources(const cc::ReturnedResourceArray& resources) final;
+ void WillDrawSurface() final;
// This enum is used in histogram, so it should be append-only.
enum OffscreenCanvasCommitType {
@@ -51,11 +53,12 @@ class PLATFORM_EXPORT OffscreenCanvasFrameDispatcherImpl final
OffscreenCanvasCommitTypeCount,
};
- void reshape(int width, int height) override;
-
private:
// Surface-related
cc::SurfaceIdAllocator m_surfaceIdAllocator;
+ void scheduleSyntheticBeginFrame(); // To be removed (crbug.com/674744)
+
+ TaskHandle m_syntheticBeginFrameTask; // To be removed (crbug.com/674744)
const cc::FrameSinkId m_frameSinkId;
cc::LocalFrameId m_currentLocalFrameId;

Powered by Google App Engine
This is Rietveld 408576698