Bug 763190 - WebGL readPixels shouldn't call EnsureBackbufferClearedAsNeeded - r=jgilbert
authorBenoit Jacob <bjacob@mozilla.com>
Tue, 12 Jun 2012 17:20:21 -0400
changeset 96517 d4820f5ac8255d9084ea8f7a19e38d4c0dd67c3e
parent 96516 f03bb92c31403fa5d1b7894ba16d31961b4b7b3b
child 96518 50356ba76bbf53a6a67fa693e3007e7802cb52c6
push id10577
push userbjacob@mozilla.com
push dateTue, 12 Jun 2012 21:21:33 +0000
treeherdermozilla-inbound@d4820f5ac825 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjgilbert
bugs763190
milestone16.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 763190 - WebGL readPixels shouldn't call EnsureBackbufferClearedAsNeeded - r=jgilbert
content/canvas/src/WebGLContextGL.cpp
--- a/content/canvas/src/WebGLContextGL.cpp
+++ b/content/canvas/src/WebGLContextGL.cpp
@@ -3928,18 +3928,16 @@ WebGLContext::ReadPixels(WebGLint x, Web
     }
 
     MakeContextCurrent();
 
     if (mBoundFramebuffer) {
         // prevent readback of arbitrary video memory through uninitialized renderbuffers!
         if (!mBoundFramebuffer->CheckAndInitializeRenderbuffers())
             return ErrorInvalidFramebufferOperation("readPixels: incomplete framebuffer");
-    } else {
-        EnsureBackbufferClearedAsNeeded();
     }
     // Now that the errors are out of the way, on to actually reading
 
     // If we won't be reading any pixels anyways, just skip the actual reading
     if (width == 0 || height == 0)
         return DummyFramebufferOperation("readPixels");
 
     if (CanvasUtils::CheckSaneSubrectSize(x, y, width, height, framebufferWidth, framebufferHeight)) {