Commit Graph

2854 Commits

Author SHA1 Message Date
gohai
df696cb722 Unconditionally disable POLYGON_SMOOTH in restoreGL()
This now matches the logic in setGLSettings(), as suggested by @JakubValtar.
2018-07-01 10:54:45 -07:00
gohai
4f3f197582 ARM Mali: Don't use GL_MULTISAMPLE or GL_POLYGON_SMOOTH on ES
Fixes:
GLDebugEvent[ id 0x32
    type Error
    severity High: dangerous undefined behavior
    source GL API
    msg Error:glEnable::<cap> is not one of the accepted values
    when 1524184964512
    source 3.1 (ES profile, arb, debug, compat[ES2, ES3, ES31], FBO, hardware) - OpenGL ES 3.1 v1.r17p0-01rel0.a881d28363cdb20f0017ed13c980967e - hash 0x1f928e9]
    [2]: jogamp.opengl.GLDebugMessageHandler$StdErrGLDebugListener.messageSent(GLDebugMessageHandler.java:347)
    [3]: jogamp.opengl.GLDebugMessageHandler.sendMessage(GLDebugMessageHandler.java:332)
    [4]: jogamp.opengl.GLDebugMessageHandler.glDebugMessageARB(GLDebugMessageHandler.java:358)
    [5]: jogamp.opengl.es3.GLES3Impl.dispatch_glEnable1(Native Method)
    [6]: jogamp.opengl.es3.GLES3Impl.glEnable(GLES3Impl.java:734)
    [7]: com.jogamp.opengl.DebugGLES3.glEnable(DebugGLES3.java:2121)
    [8]: processing.opengl.PJOGL.enable(PJOGL.java:1068)
    [9]: processing.opengl.PGraphicsOpenGL.setGLSettings(PGraphicsOpenGL.java:6784)
    [10]: processing.opengl.PGraphicsOpenGL.checkSettings(PGraphicsOpenGL.java:6740)
    [11]: processing.opengl.PGraphicsOpenGL.beginDraw(PGraphicsOpenGL.java:1463)
    [12]: processing.core.PApplet.handleDraw(PApplet.java:2388)
    [13]: processing.opengl.PSurfaceJOGL$DrawListener.display(PSurfaceJOGL.java:866)
    [14]: jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:692)
    [15]: jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:674)
    [16]: jogamp.opengl.GLAutoDrawableBase$2.run(GLAutoDrawableBase.java:443)
    [17]: jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1293)
    [18]: jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:1147)
    [19]: com.jogamp.newt.opengl.GLWindow.display(GLWindow.java:759)
    [20]: com.jogamp.opengl.util.AWTAnimatorImpl.display(AWTAnimatorImpl.java:81)
    [21]: com.jogamp.opengl.util.AnimatorBase.display(AnimatorBase.java:452)
    [22]: com.jogamp.opengl.util.FPSAnimator$MainTask.run(FPSAnimator.java:178)
    [23]: java.util.TimerThread.mainLoop(Timer.java:555)
    [24]: java.util.TimerThread.run(Timer.java:505)
2018-07-01 10:54:45 -07:00
gohai
f3a718f294 ARM Mali: Don't assume anisotropic filtering for gl3es3
Fixes:
GLDebugEvent[ id 0xb
    type Error
    severity High: dangerous undefined behavior
    source GL API
    msg Error:glGetFloatv::<pname> is not an accepted value
    when 1524036153380
    source 3.1 (ES profile, arb, debug, compat[ES2, ES3, ES31], FBO, hardware) - OpenGL ES 3.1 v1.r17p0-01rel0.a881d28363cdb20f0017ed13c980967e - hash 0xc39cf5]
    [2]: jogamp.opengl.GLDebugMessageHandler$StdErrGLDebugListener.messageSent(GLDebugMessageHandler.java:347)
    [3]: jogamp.opengl.GLDebugMessageHandler.sendMessage(GLDebugMessageHandler.java:332)
    [4]: jogamp.opengl.GLDebugMessageHandler.glDebugMessageARB(GLDebugMessageHandler.java:358)
    [5]: jogamp.opengl.es3.GLES3Impl.dispatch_glGetFloatv1(Native Method)
    [6]: jogamp.opengl.es3.GLES3Impl.glGetFloatv(GLES3Impl.java:1157)
    [7]: com.jogamp.opengl.DebugGLES3.glGetFloatv(DebugGLES3.java:3260)
    [8]: processing.opengl.PJOGL.getFloatv(PJOGL.java:1106)
    [9]: processing.opengl.PGraphicsOpenGL.getGLParameters(PGraphicsOpenGL.java:6892)
    [10]: processing.opengl.PGraphicsOpenGL.beginDraw(PGraphicsOpenGL.java:1454)
    [11]: processing.core.PApplet.handleDraw(PApplet.java:2388)
    [12]: processing.opengl.PSurfaceJOGL$DrawListener.display(PSurfaceJOGL.java:866)
    [13]: jogamp.opengl.GLDrawableHelper.displayImpl(GLDrawableHelper.java:692)
    [14]: jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:674)
    [15]: jogamp.opengl.GLAutoDrawableBase$2.run(GLAutoDrawableBase.java:443)
    [16]: jogamp.opengl.GLDrawableHelper.invokeGLImpl(GLDrawableHelper.java:1293)
    [17]: jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:1147)
    [18]: com.jogamp.newt.opengl.GLWindow.display(GLWindow.java:759)
    [19]: com.jogamp.opengl.util.AWTAnimatorImpl.display(AWTAnimatorImpl.java:81)
    [20]: com.jogamp.opengl.util.AnimatorBase.display(AnimatorBase.java:452)
    [21]: com.jogamp.opengl.util.FPSAnimator$MainTask.run(FPSAnimator.java:178)
    [22]: java.util.TimerThread.mainLoop(Timer.java:555)
    [23]: java.util.TimerThread.run(Timer.java:505)
2018-07-01 10:08:19 -07:00
gohai
627ac902b3 ARM Mali: Implement gDrawBuffer for gl3es3
I don't know IntBuffer and OpenGL well enought to say if this will leak memory or similar.
2018-07-01 10:08:06 -07:00
gohai
a9a2928082 ARM Mali: Implement glBlitFramebuffer for gl3es3
Fixes:
java.lang.RuntimeException: GL function glBlitFramebuffer() is not available on this hardware (or driver) Read <a href="http://wiki.processing.org/w/OpenGL_Issues" target="_blank" rel="nofollow">http://wiki.processing.org/w/OpenGL_Issues</a> for help.
    at processing.opengl.PJOGL.blitFramebuffer(PJOGL.java:1939)
    at processing.opengl.PGL.syncBackTexture(PGL.java:595)
    at processing.opengl.PGL.endRender(PGL.java:769)
    at processing.opengl.PGraphicsOpenGL.endOnscreenDraw(PGraphicsOpenGL.java:6598)
    at processing.opengl.PGraphicsOpenGL.endDraw(PGraphicsOpenGL.java:1483)
    at processing.core.PApplet.handleDraw(PApplet.java:2444)
    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)
2018-07-01 10:08:00 -07:00
gohai
1c0b6e1448 ARM Mali: Specify precision for _fragColor
Fixes:
S0032: no default precision defined for variable '_fragColor'
2018-07-01 10:07:53 -07:00
gohai
715c1fe473 ARM Mali: Report "es" as part of GLSL versions
Fixes:
P0007: Language version '300' unknown, this compiler only supports up to version '320 es'
2018-07-01 10:07:45 -07:00
gohai
b2ab9fc20a ARM Mali: Implement glReadBuffer for gl3es3
Fixes:
java.lang.RuntimeException: GL function glReadBuffer() is not available on this hardware (or driver) Read <a href="http://wiki.processing.org/w/OpenGL_Issues" target="_blank" rel="nofollow">http://wiki.processing.org/w/OpenGL_Issues</a> 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)
2018-07-01 10:07:39 -07:00
gohai
3a6f62a05c ARM Mali: Implement glRenderbufferStorageMultisample for gl3es3
Fixes:
java.lang.RuntimeException: GL function glRenderbufferStorageMultisample() is not available on this hardware (or driver) Read <a href="http://wiki.processing.org/w/OpenGL_Issues" target="_blank" rel="nofollow">http://wiki.processing.org/w/OpenGL_Issues</a> for help.
    at processing.opengl.PJOGL.renderbufferStorageMultisample(PJOGL.java:1941)
    at processing.opengl.PGL.createFBOLayer(PGL.java:955)
    at processing.opengl.PGL.beginRender(PGL.java:727)
    at processing.opengl.PGraphicsOpenGL.beginOnscreenDraw(PGraphicsOpenGL.java:6577)
    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)
2018-07-01 10:07:32 -07:00
gohai
86f2b79f8d Increase the maximum number of lights to 4 for Mesa vc4
Testing on the latest Raspbian release shows that the open-source Mesa driver can handle 4 lights on all P3D examples without tripping up during register allocation. Still an issue with 8 lights, so leave it at 4 for now, and re-test with 6 next time around.
2018-07-01 10:07:14 -07:00
Ben Fry
5438127cbf reorg a bit, also note fix for #5406 2018-03-13 20:24:52 -04:00
Ben Fry
636c309bb5 fix ArrayIndexOutOfBoundsException in Table.insertRow() (fixes #5406) 2018-03-13 20:15:29 -04:00
Ben Fry
308af685d0 Merge pull request #5384 from hazmatsuitor/master
fix NPE when closing sketch window on Mac (#5214)
2018-03-13 19:55:27 -04:00
Ben Fry
90f94a17a9 deal with quirk in extension parsing when no extension found (fixes #5326) 2018-02-14 21:47:21 -05:00
codeanticode
54fba5da9e cap framerate at 1000 in OpenGL 2018-02-13 02:13:45 -05:00
Miles Fogle
2ed9ba283b fix NPE when closing sketch window on Mac (#5214)
This fixes the first error mentioned in the issue, but not the other one mentioned by @christianbender. Tested on macOS High Sierra (10.13.2)
2018-01-27 15:22:54 -06:00
Jakub Valtar
a9e944f60c Make un/registering methods in PApplet thread-safe 2018-01-22 21:10:05 +01:00
codeanticode
6ff0c6f3e6 reset correct clear variable 2018-01-18 10:15:29 -05:00
codeanticode
e9707b81a0 some additions to the PLG.Tessellator interface 2018-01-13 14:16:02 -05:00
Ben Fry
99375f3681 Merge pull request #5354 from JakubValtar/linevert-norm-fix
Fix line join triangles
2018-01-12 07:21:26 -05:00
Ben Fry
f806cb4748 Merge pull request #5297 from gohai/arm-updates
ARM updates
2018-01-12 07:19:30 -05:00
Jakub Valtar
591f79ce90 Fix line join triangles
Fixes #5353
2018-01-06 16:47:22 +01:00
Alexander Hurst
a9cc453015 cursor() sets the cursor visible, fixes #5330 2017-12-20 15:09:16 -05:00
codeanticode
fb47853b1b texture wrap can be set multiple times in a sketch, fixes #5322 2017-12-08 15:28:18 +09:00
Ben Fry
f4452c0781 set colorModeDefault to true by default 2017-11-20 16:06:21 -05:00
REAS
a3943ee508 Small parameter changes for Reference 2017-11-10 14:41:32 -08:00
gohai
cdfaa11a6c Fix 3D on Raspberry Pi with Mesa drivers
We need to use a special shader to workaround register allocation issues with the new driver, see: https://github.com/anholt/mesa/issues/63
2017-10-30 21:12:08 +01:00
Ben Fry
1b84d46587 remove unhelpful deprecation, other notes and todo items 2017-10-29 17:32:19 -04:00
Ben Fry
4b4284b7df better handling of Java version, previous only worked for 9 2017-10-20 17:20:36 -04:00
Ben Fry
34f9caa137 deal with a handful of Java 9 changes and deprecations 2017-10-18 22:42:13 -04:00
Ben Fry
316c06d20a Merge pull request #5282 from jeremydouglass/patch-1
Remove "Pipe Organ" from exec javadoc
2017-10-18 16:35:18 -04:00
Ben Fry
f26cff6493 Merge pull request #5251 from Prince-Polka/master
BezierPoint
2017-10-18 15:41:29 -04:00
Ben Fry
a86e220096 fix minor spacing issue with indent 2017-10-17 23:09:17 -04:00
Ben Fry
8b9b976d67 minor type erasure edits 2017-10-17 23:08:50 -04:00
Jeremy Douglass
19d20f5915 Remove "Pipe Organ" from exec javadoc
Recent OS X releases no longer come with the "Pipe Organ" voice installed by default. As a result, the exec example fails silently with no console feedback. Removing the -v voice argument causes the example to work on current OS X -- and still work on older OS X.
2017-10-15 09:35:15 -07:00
Ben Fry
09de1fad83 fix entries() Iterator in IntDict, FloatDict, StringDict 2017-10-11 16:25:16 -04:00
Ben Fry
2dde225eae erase unnecessary types 2017-10-10 21:00:32 -04:00
Ben Fry
65b138de31 added resize() to IntDict, FloatDict, StringDict 2017-10-10 20:57:27 -04:00
Ben Fry
2327009d88 add setIndex() method 2017-10-10 20:34:40 -04:00
Ben Fry
5d4a48a814 handle version number parsing for JDK 9 (fixes #5275) 2017-09-29 23:15:17 -04:00
Prince-Polka
6a018b7a94 Update PGraphics.java 2017-09-20 17:18:50 +02:00
Prince-Polka
4dd1f29cb8 Update PGraphics.java 2017-09-08 19:16:33 +02:00
Prince-Polka
3052c1f384 Update PGraphics.java 2017-09-08 19:15:09 +02:00
Prince-Polka
2746369547 Update PGraphics.java
At row 3214 changed  

public float bezierPoint(float a, float b, float c, float d, float t) {
  float t1 = 1.0f - t;
  return a*t1*t1*t1 + 3*b*t*t1*t1 + 3*c*t*t*t1 + d*t*t*t;
}

to  

float bezierPoint (float a, float b, float c, float d, float t) {
  float t1 = t-1.0f;
  return t * ( 3*t1*(b*t1-c*t) + d*t*t ) - a*t1*t1*t1;
}
, works the same but faster
2017-09-08 19:12:59 +02:00
Ben Fry
82c772f178 Windows ignores setMinimumSize(), add workaround for #5052 2017-09-03 08:36:23 -04:00
Ben Fry
f1dd1554ee Merge pull request #5234 from kisarur/master
A fix for the window resizing problem in Windows
2017-09-03 08:26:45 -04:00
kisarur
b6b1ed8c79 removed partial fixes added earlier 2017-08-28 03:43:10 +05:30
kisarur
114d3788c1 a working fix for the window resizing to zero issue in Windows was added 2017-08-28 03:23:47 +05:30
Ben Fry
f8616cad9f Merge pull request #5184 from JakubValtar/fix-line-vert
Fix bugs in line vert shader
2017-08-22 09:47:55 -04:00
Ben Fry
b2f96d3814 todo notes and disable unused shellQuoted() method 2017-08-07 22:21:59 -04:00