Bug 805002 - Flush accelerated Quartz canvas before GL composition. r=BenWa
--- a/gfx/layers/opengl/CanvasLayerOGL.cpp
+++ b/gfx/layers/opengl/CanvasLayerOGL.cpp
@@ -220,16 +220,17 @@ CanvasLayerOGL::UpdateSurface()
if (mDrawTarget && mDrawTarget->GetNativeSurface(gfx::NATIVE_SURFACE_CGCONTEXT_ACCELERATED)) {
if (!mTexture) {
mTexture = MakeIOSurfaceTexture((CGContextRef)mDrawTarget->GetNativeSurface(
gfx::NATIVE_SURFACE_CGCONTEXT_ACCELERATED),
gl());
mTextureTarget = LOCAL_GL_TEXTURE_RECTANGLE_ARB;
mLayerProgram = gl::RGBARectLayerProgramType;
}
+ mDrawTarget->Flush();
return;
}
#endif
nsRefPtr<gfxASurface> updatedAreaSurface;
if (mCanvasGLContext) {
gfxIntSize size(mBounds.width, mBounds.height);
nsRefPtr<gfxImageSurface> updatedAreaImageSurface =