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

Unified Diff: content/browser/compositor/offscreen_browser_compositor_output_surface.cc

Issue 2352963002: cc: Make most of cc::OutputSurface abstract. (Closed)
Patch Set: outputsurface-cleanup: rebase Created 4 years, 3 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/compositor/offscreen_browser_compositor_output_surface.cc
diff --git a/content/browser/compositor/offscreen_browser_compositor_output_surface.cc b/content/browser/compositor/offscreen_browser_compositor_output_surface.cc
index eea945b4d044bb289041f22c0be08b6c23a01f6f..4ef371d7ac73e3bd0350b9a1b0c647a067c491c6 100644
--- a/content/browser/compositor/offscreen_browser_compositor_output_surface.cc
+++ b/content/browser/compositor/offscreen_browser_compositor_output_surface.cc
@@ -130,11 +130,6 @@ void OffscreenBrowserCompositorOutputSurface::BindFramebuffer() {
}
}
-GLenum
-OffscreenBrowserCompositorOutputSurface::GetFramebufferCopyTextureFormat() {
- return GLCopyTextureInternalFormat(kFboTextureFormat);
-}
-
void OffscreenBrowserCompositorOutputSurface::SwapBuffers(
cc::CompositorFrame frame) {
if (reflector_) {
@@ -155,8 +150,29 @@ void OffscreenBrowserCompositorOutputSurface::SwapBuffers(
gpu::SyncToken sync_token;
gl->GenUnverifiedSyncTokenCHROMIUM(fence_sync, sync_token.GetData());
context_provider_->ContextSupport()->SignalSyncToken(
- sync_token, base::Bind(&OutputSurface::OnSwapBuffersComplete,
- weak_ptr_factory_.GetWeakPtr()));
+ sync_token,
+ base::Bind(
+ &OffscreenBrowserCompositorOutputSurface::OnSwapBuffersComplete,
+ weak_ptr_factory_.GetWeakPtr()));
+}
+
+bool OffscreenBrowserCompositorOutputSurface::IsDisplayedAsOverlayPlane()
+ const {
+ return false;
+}
+
+unsigned OffscreenBrowserCompositorOutputSurface::GetOverlayTextureId() const {
+ return 0;
+}
+
+bool OffscreenBrowserCompositorOutputSurface::SurfaceIsSuspendForRecycle()
+ const {
+ return false;
+}
+
+GLenum
+OffscreenBrowserCompositorOutputSurface::GetFramebufferCopyTextureFormat() {
+ return GLCopyTextureInternalFormat(kFboTextureFormat);
}
void OffscreenBrowserCompositorOutputSurface::OnReflectorChanged() {
@@ -164,4 +180,8 @@ void OffscreenBrowserCompositorOutputSurface::OnReflectorChanged() {
EnsureBackbuffer();
}
+void OffscreenBrowserCompositorOutputSurface::OnSwapBuffersComplete() {
+ client_->DidSwapBuffersComplete();
+}
+
} // namespace content

Powered by Google App Engine
This is Rietveld 408576698