summaryrefslogtreecommitdiffstats
path: root/make/scripts/tests.sh
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2020-02-24 05:07:15 +0100
committerSven Gothel <[email protected]>2020-02-24 05:07:15 +0100
commitd1a4d790c89934616fa1883312b4064bda9fa420 (patch)
tree5d2bd10fb4d8a35afceaac057aef90531c241857 /make/scripts/tests.sh
parent78b96b89a68ff35969aea83de294cd3cc1178f26 (diff)
Bug 1398: MacOS: Perform [NSOpenGLContext setView:] on main-thread async w/o blocking
Set NSOpenGLContext's NSView via [NSOpenGLContext setView:] on the main-thread as enforced since XCode 11 using SDL macosx10.15, using Runnable SetNSViewCmd. This operation must be performed async w/o blocking to allow other tasks locking the NativeSurface on main-thread to complete. Further, since [NSOpenGLContext setView:] acquired the CGLContext lock, it can't be locked until this task has been completed. Worst case scenario for a late [NSOpenGLContext setView:] issuance might be corrupt initial frame(s) displayed. Since all concurrent locking is performed within JOGL, the unlocked CGLContext window risk is only academic. However, if native 3rd party toolkits take share control, we might have a situation. +++ SetNSViewCmd is issued @ makeCurrent() now as opposed to createContext(..) and associateDrawable(true). The latter was actually late as well, as it also happened after makeCurrent when updating the drawable association. It also missed setting a null NSView when detached! release() will also set a null NSView if called after associateDrawable(false). SetNSViewCmd will only be issued if the NSView has been changed, i.e. first makeCurrent() or changing the drawable. If issued, makeCurrent() will not lock the underlying CGLContext and hence allow SetNSViewCmd to perform - see above. +++ NSViewDescriptor class structure replaces the less convenient method 'getNSViewHandle(..)', exposing all collected drawable characteristics as fields. NSViewDescriptor also respects a ProxySurface's OPT_UPSTREAM_SURFACELESS mode, which results in not using any underlying NSView - similar to OPT_UPSTREAM_WINDOW_INVISIBLE. This change ensures that all surfaceless GL operations will not use any NSView.
Diffstat (limited to 'make/scripts/tests.sh')
-rw-r--r--make/scripts/tests.sh10
1 files changed, 8 insertions, 2 deletions
diff --git a/make/scripts/tests.sh b/make/scripts/tests.sh
index 220662262..83553b564 100644
--- a/make/scripts/tests.sh
+++ b/make/scripts/tests.sh
@@ -111,6 +111,7 @@ function jrun() {
#X_ARGS="--illegal-access=warn"
#D_ARGS="-Djogl.debug.GLProfile -Djogl.debug.GLContext"
+ D_ARGS="-Djogl.debug.GLContext -Dnativewindow.debug.OSXUtil.MainThreadChecker"
#D_ARGS="-Djogl.debug.GLProfile"
#D_ARGS="-Djogl.debug.DebugGL"
#D_ARGS="-Djogl.debug.TraceGL"
@@ -156,7 +157,7 @@ function jrun() {
#D_ARGS="-Dnativewindow.debug=all -Djogl.debug=all -Dnewt.debug=all"
#D_ARGS="-Dnativewindow.debug.SWT"
- D_ARGS="-Dnativewindow.debug.SWT -Dnewt.debug.Window -Djogl.debug.GLCanvas"
+ #D_ARGS="-Dnativewindow.debug.SWT -Dnewt.debug.Window -Djogl.debug.GLCanvas"
#D_ARGS="-Dnativewindow.debug.SWT -Dnewt.debug.Window -Djogl.debug.GLCanvas -Dswt.autoScale=200"
#export GDK_DPI_SCALE=2
#D_ARGS="-Dnativewindow.debug.SWT -Dnativewindow.debug.X11Util -Dnewt.debug.Window"
@@ -488,7 +489,7 @@ function testawtswt() {
#testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2SimpleNEWT $*
#testawt com.jogamp.opengl.test.junit.jogl.demos.es2.awt.TestGearsES2GLJPanelAWT $*
#testawt com.jogamp.opengl.test.junit.jogl.demos.es2.awt.TestGearsES2AWT $*
-testawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NewtCanvasAWT $*
+#testawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NewtCanvasAWT $*
#testswt com.jogamp.opengl.test.junit.jogl.swt.TestGLCanvasSWTNewtCanvasSWTPosInTabs $*
#testawt com.jogamp.opengl.test.junit.jogl.demos.gl2.awt.TestGearsAWT $*
#testnoawt com.jogamp.opengl.test.junit.jogl.glsl.TestRulerNEWT01 $*
@@ -964,6 +965,11 @@ testawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NewtCanvasA
#testawt com.jogamp.opengl.test.junit.jogl.awt.TestBug572AWT $*
#testawt com.jogamp.opengl.test.junit.jogl.perf.TestPerf001GLJPanelInit02AWT $*
#testawt com.jogamp.opengl.test.junit.newt.event.TestNewtEventModifiersAWTCanvas $*
+#
+# OSX Bug 1398
+#testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestSharedContextVBOES2NEWT1 $*
+#testnoawt com.jogamp.opengl.test.junit.graph.TestTextRendererNEWT10 $*
+testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $*
# Linux DRM/GBM
#