From 78e376a39edc9fcde6de941e00fc6bf9fbefe1f0 Mon Sep 17 00:00:00 2001 From: gohai Date: Tue, 17 Apr 2018 18:01:52 -0700 Subject: [PATCH] ARM Mali: Implement glReadBuffer for gl3es3 Fixes: java.lang.RuntimeException: GL function glReadBuffer() is not available on this hardware (or driver) Read http://wiki.processing.org/w/OpenGL_Issues for help. at processing.opengl.PJOGL.readBuffer(PJOGL.java:1954) at processing.opengl.PJOGL.initFBOLayerES(PJOGL.java:310) at processing.opengl.PJOGL.initFBOLayer(PJOGL.java:301) at processing.opengl.PGL.createFBOLayer(PGL.java:988) at processing.opengl.PGL.beginRender(PGL.java:727) at processing.opengl.PGraphicsOpenGL.beginOnscreenDraw(PGraphicsOpenGL.java:6576) at processing.opengl.PGraphicsOpenGL.beginDraw(PGraphicsOpenGL.java:1459) at processing.core.PApplet.handleDraw(PApplet.java:2388) at processing.opengl.PSurfaceJOGL$DrawListener.display(PSurfaceJOGL.java:866) at jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:692) at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:674) at jogamp.opengl.GLAutoDrawableBase$2.run(GLAutoDrawableBase.java:443) at jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1293) at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:1147) at com.jogamp.newt.opengl.GLWindow.display(GLWindow.java:759) at com.jogamp.opengl.util.AWTAnimatorImpl.display(AWTAnimatorImpl.java:81) at com.jogamp.opengl.util.AnimatorBase.display(AnimatorBase.java:452) at com.jogamp.opengl.util.FPSAnimator$MainTask.run(FPSAnimator.java:178) at java.util.TimerThread.mainLoop(Timer.java:555) at java.util.TimerThread.run(Timer.java:505) --- core/src/processing/opengl/PJOGL.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/src/processing/opengl/PJOGL.java b/core/src/processing/opengl/PJOGL.java index 42d17a0c6..b1ff43677 100644 --- a/core/src/processing/opengl/PJOGL.java +++ b/core/src/processing/opengl/PJOGL.java @@ -1950,6 +1950,8 @@ public class PJOGL extends PGL { gl2x.glReadBuffer(buf); } else if (gl3 != null) { gl3.glReadBuffer(buf); + } else if (gl3es3 != null) { + gl3es3.glReadBuffer(buf); } else { throw new RuntimeException(String.format(MISSING_GLFUNC_ERROR, "glReadBuffer()")); }