From 31be7199ca6729614853df76a2277d20f96e9e1b Mon Sep 17 00:00:00 2001 From: Jeff Gilbert Date: Fri, 16 Dec 2011 14:24:46 -0800 Subject: [PATCH] Bug 708124 - Remove unnecessary glFlushs from Layers - r=bjacob --- gfx/layers/basic/BasicLayers.cpp | 4 ---- gfx/layers/d3d10/CanvasLayerD3D10.cpp | 4 ---- gfx/layers/d3d9/CanvasLayerD3D9.cpp | 4 ---- 3 files changed, 12 deletions(-) diff --git a/gfx/layers/basic/BasicLayers.cpp b/gfx/layers/basic/BasicLayers.cpp index 4b36aa12a86..ac6cd825063 100644 --- a/gfx/layers/basic/BasicLayers.cpp +++ b/gfx/layers/basic/BasicLayers.cpp @@ -1140,10 +1140,6 @@ BasicCanvasLayer::UpdateSurface(gfxASurface* aDestSurface) NS_ASSERTION(isurf->Stride() == mBounds.width * 4, "gfxImageSurface stride isn't what we expect!"); - // We have to flush to ensure that any buffered GL operations are - // in the framebuffer before we read. - mGLContext->fFlush(); - PRUint32 currentFramebuffer = 0; mGLContext->fGetIntegerv(LOCAL_GL_FRAMEBUFFER_BINDING, (GLint*)¤tFramebuffer); diff --git a/gfx/layers/d3d10/CanvasLayerD3D10.cpp b/gfx/layers/d3d10/CanvasLayerD3D10.cpp index 00db9ac60c0..db9ad4ceb4d 100644 --- a/gfx/layers/d3d10/CanvasLayerD3D10.cpp +++ b/gfx/layers/d3d10/CanvasLayerD3D10.cpp @@ -181,10 +181,6 @@ CanvasLayerD3D10::UpdateSurface() mGLContext->MakeCurrent(); - // We have to flush to ensure that any buffered GL operations are - // in the framebuffer before we read. - mGLContext->fFlush(); - PRUint32 currentFramebuffer = 0; mGLContext->fGetIntegerv(LOCAL_GL_FRAMEBUFFER_BINDING, (GLint*)¤tFramebuffer); diff --git a/gfx/layers/d3d9/CanvasLayerD3D9.cpp b/gfx/layers/d3d9/CanvasLayerD3D9.cpp index a84c50a4524..c24e28c2347 100644 --- a/gfx/layers/d3d9/CanvasLayerD3D9.cpp +++ b/gfx/layers/d3d9/CanvasLayerD3D9.cpp @@ -119,10 +119,6 @@ CanvasLayerD3D9::UpdateSurface() mGLContext->MakeCurrent(); - // We have to flush to ensure that any buffered GL operations are - // in the framebuffer before we read. - mGLContext->fFlush(); - PRUint32 currentFramebuffer = 0; mGLContext->fGetIntegerv(LOCAL_GL_FRAMEBUFFER_BINDING, (GLint*)¤tFramebuffer);