From 33a719615c43b63bbcf9cb4a524f48d21baa7bf0 Mon Sep 17 00:00:00 2001 From: phil Date: Tue, 22 Nov 2016 16:04:48 +1300 Subject: gl2es2pipeline used JAWT instead of OffscreenLayerOption This unnecessarily bound closer to awt --- src/main/java/org/jogamp/java3d/Jogl2es2Pipeline.java | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/src/main/java/org/jogamp/java3d/Jogl2es2Pipeline.java b/src/main/java/org/jogamp/java3d/Jogl2es2Pipeline.java index 950e17b..ace4183 100644 --- a/src/main/java/org/jogamp/java3d/Jogl2es2Pipeline.java +++ b/src/main/java/org/jogamp/java3d/Jogl2es2Pipeline.java @@ -67,6 +67,7 @@ import com.jogamp.nativewindow.CapabilitiesChooser; import com.jogamp.nativewindow.GraphicsConfigurationFactory; import com.jogamp.nativewindow.NativeSurface; import com.jogamp.nativewindow.NativeWindowFactory; +import com.jogamp.nativewindow.OffscreenLayerOption; import com.jogamp.nativewindow.ProxySurface; import com.jogamp.nativewindow.UpstreamSurfaceHook; import com.jogamp.nativewindow.VisualIDHolder; @@ -8211,11 +8212,15 @@ class Jogl2es2Pipeline extends Jogl2es2DEPPipeline return false; JoglDrawable joglDrawble = (JoglDrawable) cv.drawable; - JAWTWindow jawtwindow = (JAWTWindow) joglDrawble.getNativeWindow(); - if (jawtwindow == null) - return false; - - return jawtwindow.isOffscreenLayerSurfaceEnabled(); + if (joglDrawble.getNativeWindow() instanceof OffscreenLayerOption) + { + OffscreenLayerOption olo = (OffscreenLayerOption) joglDrawble.getNativeWindow(); + if (olo == null) + return false; + else + return olo.isOffscreenLayerSurfaceEnabled(); + } + return false; } static boolean hasFBObjectSizeChanged(JoglDrawable jdraw, int width, int height) -- cgit v1.2.3