Browse Source

restore the correct framebuffer after readPixels is done

David Catuhe 8 năm trước cách đây
mục cha
commit
02016fe1f2
3 tập tin đã thay đổi với 12603 bổ sung12603 xóa
  1. 6301 6301
      dist/preview release/babylon.d.ts
  2. 6301 6301
      dist/preview release/babylon.module.d.ts
  3. 1 1
      src/babylon.engine.ts

Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 6301 - 6301
dist/preview release/babylon.d.ts


Những thai đổi đã bị hủy bỏ vì nó quá lớn
+ 6301 - 6301
dist/preview release/babylon.module.d.ts


+ 1 - 1
src/babylon.engine.ts

@@ -4169,7 +4169,7 @@
             }
 
             gl.readPixels(0, 0, width, height, gl.RGBA, readType, buffer);
-            gl.bindFramebuffer(gl.FRAMEBUFFER, null);
+            gl.bindFramebuffer(gl.FRAMEBUFFER, this._currentFramebuffer);
 
             return buffer;
         }