summaryrefslogtreecommitdiffstats
path: root/src/graphui/classes/jogamp
Commit message (Collapse)AuthorAgeFilesLines
* GraphUI GraphShape: createGLRegion() -> updateGLRegion(), called by ↵Sven Gothel2023-04-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | addShapeToRegion() impl to utilize OutlineShape -> GLRegion ctor w/ proper buffer-size This way we avoid unnecessary buffer growth and allow creation of 'always' fitting buffer sizes. +++ Update or freshly create the GLRegion, while allocating its buffers with given initial `vertexCount` and `indexCount`. Method shall be invoked by the addShapeToRegion(GLProfile, GL2ES2) implementation before actually adding the OutlineShape to the GLRegion. addShapeToRegion(GLProfile, GL2ES2) is capable to determine initial `vertexCount` and `indexCount` buffer sizes, as it composes the OutlineShapes to be added. updateGLRegion(GLProfile, GL2ES2, TextureSequence, OutlineShape) maybe used for convenience. In case GLRegion is `null`, a new instance is being created. In case the GLRegion already exists, it will be either cleared if the GL2ES2 `gl` instance is not `null` or earmarked for deletion at a later time and a new instance is being created.
* Graph + GraphUI: Consolidate Vertex: Drop SVertex and factory, use Vec[234]f ↵Sven Gothel2023-04-181-7/+9
| | | | | | | | | | | instead of float[] and remove unused VectorUtil methods After Matrix4f consolidation and proving same or better performance on non array types, this enhances code readability, simplifies API, reduces bugs and may improve performance. GraphUI: - Have RoundButton as a functional class to make a round or rectangular backdrop, i.e. impl. addShapeToRegion() via reused addRoundShapeToRegion()
* GraphUI TreeTool: Iterate from start to end (not vice versa), eliminating ↵Sven Gothel2023-04-121-4/+4
| | | | potential side-effects - fixing forSortedAll(..)
* GraphUI TreeTool: For all forAll*(): Allow acting upon Container Shape, i.e. ↵Sven Gothel2023-04-101-22/+14
| | | | | | 1st visit Shape, only therafter (if false) traverse into Container This is required to allow actions on a Container itself.
* GraphUI: Adopting Vec*f API; Adding Group; Scene + Group are Container, ↵Sven Gothel2023-04-052-2/+162
| | | | | | | | | | | | | | | | 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.
* GraphUI Button: Simplify addShapeToRegion()Sven Gothel2023-03-281-2/+2
|
* GraphUI: Promote API to JOGL via graphui.jar or within any jogl-all*.jar (WIP)Sven Gothel2023-03-101-0/+81
Root package is 'com.jogamp.graph.ui.gl', i.e. a sub-package of Graph denoting UI and OpenGL usage. Implementation will stay small, hence relative files size costs are minimal. Source and build is in parallel to nativewindow, jogl and newt and has a dependency to all of them. The NEWT dependencies are merely the input listener ..