aboutsummaryrefslogtreecommitdiffstats
path: root/src/graphui/classes/com/jogamp/graph/ui/Container.java
Commit message (Collapse)AuthorAgeFilesLines
* Bug 1498: Change Top-Level Widget Mode: Register a top-level Group in Scene, ↵Sven Göthel2024-02-051-3/+0
| | | | | | | | | | | | | | | | | | | | | | | where its zOffset gets adjusted when activated.. .. instead of having a non-working complicated callback orgy setup. This also takes away the getAdjustedZ() overloading burden (or better uglyness) etc. Hence Group's setWidgetMode(boolean) became: - enableTopLevelWidget(Scene) - disableTopLevelWidget() The forwardActivation listener is still applied to all children as well as isActive() is also still overloaded for same required behavior. However, none of the children is set in 'widget mode' as well as the Group is simply added to (or removed from) the Scene's top-level Group list - the holder. Scene's setActiveShape(Shape) and releaseActiveShape() handle the top-level Group if affected, i.e. adding or zero'ing its ZOffset.
* GraphUI Cleanup: Use TreeTool directly (Reduce virtl-funcs); Fix typos; Use ↵Sven Göthel2024-02-041-51/+0
| | | | | | PointerListener for onClicked(), add onHover(); Subsequent commits will fix complete cleanup where code was changed mostly regarding other issues.
* Bug 1489 - GraphUI Group: Resolve Performance Regression in ↵Sven Göthel2024-01-221-10/+79
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Scene.pickShape(): Drop invisible and clipped shapes After implementing Bug 1487 (Frustum Clipping/Culling) and using thousands of shapes within one Group mostly culled (outside of frustum), overall mouse Scene.pickShape() caused tremendous lagging. This is caused by Scene.pickShape() traversing through _all_ shapes, rendered ones, invisible ones and culled ones. +++ Solution is to have Scene and Group provide a pre-sorted list of actually rendered shapes, i.e. isVisible() and not culled. Scene.pickShape() can now use this reduced and pre-sorted list reducing the load considerably. +++ Further - cleanup TreeTool - rename Container methods: -- setFrustumCullingEnabled() -> setPMvCullingEnabled() -- isFrustumCullingEnabled() -> isPMvCullingEnabled() - supply Container with -- isCullingEnabled() -- List<Shape> getRenderedShapes() -- isOutside() -- isOutside2() -- forAllRendered()
* GraphUI Cleanup: Simplify Shape.draw*() and ↵Sven Göthel2024-01-071-11/+18
| | | | | | | | | | | | | Container.{add,remove*}Shape[s](); Remove Scene.setDebugBorderBox() Simplify Shape/Scene - Split scene.display()/shape.drawImpl0() and scene.displayGLSelect()/shape.drawToSelectImpl0() Simplify Container (Scene/Group) - {add,remove*}Shape[s](), i.e. drop unusual removeShape*() and simplify implementation Scene - Remove setDebugBorderBox()
* Bug 805: GraphUI: Add Group.replaceShape(..) and Shape.getParent()Sven Gothel2023-12-181-0/+1
| | | | | | | | Group.replaceShape(..) allows replacing a shape w/o disturbing a layout, e.g. to zoom one element by taking it out of a grid-group and placing it on-top of the Scene while using a placeholder in the grid until returned. Shape.getParent() - depending on use-case (w/o DAG) - allows access and control of a shape's Group.
* GraphUI Shape: 'int name' -> 'int id' and add 'String name', change get/set ↵Sven Gothel2023-10-031-0/+4
| | | | methods accordingly
* Bug 1462 - Graph Font: Add name + codepoint to ID and Glyph mapping plus ↵Sven Gothel2023-09-241-1/+1
| | | | | | | | | traversing through all Glyphs See UISceneDemo03 new Button(options.renderModes, fontSymbols, " "+fontSymbols.getUTF16String("pause")+" ", buttonWidth, buttonHeight); // pause Unicode codepoint symbol is also contained in FontGlyph
* GraphUI Container: Add getShapeCount() and add API doc ..Sven Gothel2023-09-201-0/+5
|
* Bug 1452 - Decouple math functionality to 'com.jogamp.math' to be toolkit ↵Sven Gothel2023-09-201-12/+11
| | | | | | | | | | | | | | | | | | | | agnostic (PMVMatrix, Matrix4f, Vec4f, ..) Math functionality (PMVMatrix, Matrix4f, Vec4f, ..) - shall be used toolkit agnostic, e.g. independent from OpenGL - shall be reused within our upcoming Vulkan implementation - may also move outside of JOGL, i.e. GlueGen or within its own package to be reused for other purposed. The 'com.jogamp.opengl.util.PMVMatrix' currently also used to feed in GLUniformData via the toolkit agnostic SyncAction and SyncBuffer shall also be split to a toolkit agnostic variant. An OpenGL PMVMatrix specialization implementing GLMatrixFunc can still exist, being derived from the toolkit agnostic base implementation. +++ Initial commit .. compile clean, passing most unit tests.
* GraphUI Container.removeShape(..): Return removed Shape, add ↵Sven Gothel2023-04-141-2/+12
| | | | removeShape(index) variant; Group.(add|remove)Shape(..) markShapeDirty() to recompute bbox and layout.
* GraphUI: Container (Group, Scene): Add removeAllShapes() and expose ↵Sven Gothel2023-04-101-0/+9
| | | | frustum-culling get/set
* GraphUI: Adopting Vec*f API; Adding Group; Scene + Group are Container, ↵Sven Gothel2023-04-051-0/+97
traversing the PMVMatrix throughout childs (-> see TreeTool). Utilizing the Vec*f (and Matrix4f) API w/ AABBox et al renders our code more clean & safe, see commit 15e60161787224e85172685f74dc0ac195969b51. A Group allows to contain multiple Shapes, hence the PMVMatrix must be traversed accordingly using TreeTool for all operations (draw, picking, win->obj coordinates, ..). Hence Scene + Group are now implementing Container and reuse code via TreeTool and a Shape.Visitor*. This will allow further simplification of user code.