From 0b476231be5cf4a42e7030d7e0f88589811c1c88 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Mon, 20 Mar 2023 06:18:31 +0100 Subject: GraphUI Default Scene.PMVMatrixSetup: Scale (back) projection to have normalized plane dimensions, 1 for the greater of width and height --- .../opengl/demos/graph/ui/UISceneDemo00.java | 25 ++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) (limited to 'src/demos/com/jogamp') diff --git a/src/demos/com/jogamp/opengl/demos/graph/ui/UISceneDemo00.java b/src/demos/com/jogamp/opengl/demos/graph/ui/UISceneDemo00.java index 76ee7389d..d7677ecbd 100644 --- a/src/demos/com/jogamp/opengl/demos/graph/ui/UISceneDemo00.java +++ b/src/demos/com/jogamp/opengl/demos/graph/ui/UISceneDemo00.java @@ -52,6 +52,13 @@ import com.jogamp.opengl.util.PMVMatrix; /** * Res independent Shape, in Scene attached to GLWindow showing simple linear Shape movement within one main function. + *

+ * The shape is created using the normalized scene's default bounding box, normalized to 1 for the greater of width and height. + *

+ *

+ * Pass '-keep' to main-function to keep running after animation, + * then user can test Shape drag-move and drag-resize w/ 1-pointer. + *

*/ public class UISceneDemo00 { public static void main(final String[] args) throws IOException { @@ -59,13 +66,22 @@ public class UISceneDemo00 { final int renderModes = Region.VBAA_RENDERING_BIT; final GLProfile glp = GLProfile.getGL2ES2(); + boolean keepRunning = false; + if( 0 != args.length ) { + for(int i=0; i