Sfoglia il codice sorgente

ensure no framebuffer is bound in waitForGpuCommandsCompleteSync

Alexander Rose 6 anni fa
parent
commit
3b2eab1cf9
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      src/mol-gl/webgl/context.ts

+ 1 - 0
src/mol-gl/webgl/context.ts

@@ -107,6 +107,7 @@ function waitForGpuCommandsComplete(gl: GLRenderingContext): Promise<void> {
 }
 
 function waitForGpuCommandsCompleteSync(gl: GLRenderingContext): void {
+    gl.bindFramebuffer(gl.FRAMEBUFFER, null)
     gl.readPixels(0, 0, 1, 1, gl.RGBA, gl.UNSIGNED_BYTE, tmpPixel)
 }