aboutsummaryrefslogtreecommitdiffstats
path: root/src/graphui/classes
Commit message (Collapse)AuthorAgeFilesLines
* GraphUI Margin, Alignment: Reuse ctor for default-ctorSven Gothel2023-09-042-2/+2
|
* GraphUI: Button/Label: Complete String -> CharSequence type change for text, ↵Sven Gothel2023-09-043-6/+6
| | | | rename Button set{Label->Text}(..), adjust demo/text code
* GraphUI GraphShape: Split renderModes -> final renderModesReq + mutable ↵Sven Gothel2023-09-041-2/+26
| | | | renderModes, allowing the latter to be adjusted e.g. in case a color-channel is required
* GraphUI Enhance: API doc; Scene/Button Z-offset and -epsilon; Push temp ↵Sven Gothel2023-09-048-54/+238
| | | | AffineTransform to local method; Simplify BaseButton setCorner(0) -> setPerp(); Protected abstract ctor ..
* GraphUI Button: Add label bounds to own shape (adds used z-range)Sven Gothel2023-09-031-0/+2
|
* GraphUI Scene: Expose Z-Epsilon API for default and current PMVMatrixSetup ↵Sven Gothel2023-09-032-6/+53
| | | | values; Button add Z-Epsilon API for ctor and setLabelZOffset(..)
* GraphUI Shape.ZAscendingComparator: Use (faster) FloatUtil.isEqual2(a,b) and ↵Sven Gothel2023-09-031-3/+10
| | | | consider Z-scaling
* GraphUI Shape: Enhance API doc for colorsSven Gothel2023-09-031-6/+35
|
* GraphUI Scene: Generalize its interface PMVMatrixSetup and usage of its ↵Sven Gothel2023-09-031-39/+112
| | | | DefaultPMVMatrixSetup w/o orthogonal alike scale-back but fully parametric
* GraphUI Scene: Pass sampleCount in ctor variant and refine API doc, clip to ↵Sven Gothel2023-09-031-8/+37
| | | | [1..8]; Add clarity in Region; Demos CommandlineOptions adds actual graphAASamples set and utilized
* PMVMatrix.gluPerspective(): Redfine angle in radians instead of degrees ** ↵Sven Gothel2023-09-021-2/+2
| | | | | | | | API Change ** Since this is an extra implementation of PMVMatrix and not of GLMatrixFunc, we shall use the default ISO dimension avoiding conversion. This alsi redefined Graph's RegionRenderer.reshapePerspective() angle definition from degrees to radians
* GraphUI Shape: Show dirty-state in getSubString()Sven Gothel2023-08-281-1/+13
|
* Graph Font + Glyph: More robust detetection and API definition of ↵Sven Gothel2023-08-283-8/+7
| | | | | | non-contour/whitespace Glyphs (detect and allow to skip 'em) We also drop shapes for both, but for id 0 (unknown).
* GraphUI: Button: Reduce default DEFAULT_LABEL_ZOFFSET from 0.005f -> ↵Sven Gothel2023-08-271-1/+1
| | | | | | | | | 0.0001f, have to check if working on all platforms (TODO) Otherwise, we have to resolve the 'one Region' for the Button (backgroung shape + text on top) implementation with two OutlineShapes. As of now, we use the z-offset of the text above background to avoid z-fighting. This is like a manual application of glPolygonOffset(..) directly on the produced vertices.
* GraphUI: Extract generalized AnimGroup functionality from UISceneDemo03*, ↵Sven Gothel2023-08-271-0/+812
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | providing sets of animated Shapes (GlyphShape or any other) Hardcoding the whole animation process into user code is not feasible to allow a quick add-on. GraphUI's new AnimGroup is a Group and allows to add multiple AnimGroup.Set of AnimGroup.ShapeData. +++ AnimGroup.ShapeData holds the actual Shape and its start- and target position as well as its active animation state and an optional user object attachment. AnimGroup.Set holds a list of AnimGroup.ShapeData as well as the animation properties and states like acceleration and velocity for translation and angular operations. It also contains the AnimGroup.LerpFunc for linear interpolation of the next position as called via AnimGroup.tick() over all sets. AnimGroup.LerpFunc is intended to perform the linear interpolation for the next position, either user provided or one of the provided may be used, i.e. TargetLerp, ScrollLerp and SineLerp. To setup the start- and target position for each AnimGroup.ShapeData, a AnimGroup.ShapeSetup is used - user implementated or one of the build-in of AnimGroup.addGlyphSetHorizScroll01(..), AnimGroup.assGlyphSetRandom01(..). +++ UISceneDemo03 consolidated UISceneDemo03 + UISceneDemo03b (deleted) and shows the following AnimGroup capabilities: - Two repetitive scrolling text lines. One text shorter than the line-width and one longer. - One line of animated rectangles, rotating around their z-axis - A text animation assembling one line of text, each glyph coming from from a random 3D point moving to its destination all at once including rotation. - One line of text with sine wave animation
* GraphUI: Use thread-save and lock-free CopyOnWriteArrayList for List<Shape>, ↵Sven Gothel2023-08-272-4/+4
| | | | allowing off-thread mutation
* GraphUI: Shape: Add runSynced(Runnable); Add setPMVMatrix(..) to setup ↵Sven Gothel2023-08-251-39/+100
| | | | complete PMVMatrix, use it in getSurfaceSize(..), shapeToWinCoord(..) and winToShapeCoord(..)
* GraphUI: Group API doc + remove GlyphShape's redundant many getOrigPos() ↵Sven Gothel2023-08-252-40/+7
| | | | variants
* Texture ctor w/ external textureID: Pass `ownsTextureID` where true hands ↵Sven Gothel2023-08-131-6/+10
| | | | | | | | | over ownership and allows destroy() to delete it, otherwise not. Fixes GraphUI's GLButton. GraphUI's GLButton uses the offscreen's FBO texture and hence can't pass over ownership of the texture. Hence the Texture instance is created w/o handing over ownership! GLMediaPlayerImpl does hand over ownership of the generated and passed texture to the Texture ctor.
* Graph: Simplify RegionRenderer API by exposing common RenderState methods ↵Sven Gothel2023-08-022-6/+3
| | | | (and fwd 'em to RenderState aggregate)
* Graph Add {GLRegion, GraphShape}.setTextureUnit(int): Allowing to set ↵Sven Gothel2023-08-011-2/+12
| | | | texture unit after ctor
* GraphUI: Add Shape.getSurfacePort(..): Similar to getSurfaceSize(..) but ↵Sven Gothel2023-08-011-0/+31
| | | | returns the whole Recti viewport of the shape
* GraphUI Shape: Add one-shot init callback, will be called after each ↵Sven Gothel2023-05-231-0/+22
| | | | draw(..) until it returns true.
* GraphUI Scene: Drop redundant and wrong setupMatrix(pmv) for forOne(..) and ↵Sven Gothel2023-05-231-4/+2
| | | | forAll(..), should be setup before call by user
* GraphUI MediaButton: Expose AudioSinkSven Gothel2023-05-231-0/+3
|
* GLMediaPlayer: Replace GLMediaEventListener.EVENT_CHANGE_* 'int event_mask' ↵Sven Gothel2023-05-091-6/+6
| | | | with EventMask.Bit/EventMask
* GraphUI GridLayout: Handle 'diffBL' in 2nd path, no need to store as we ↵Sven Gothel2023-04-291-10/+10
| | | | don't use PMVMatrix for computation
* GraphUI GridLayout: Remove old unused layout0(..) methodSven Gothel2023-04-291-134/+0
|
* GraphUI Working GridLayout w/ and w/o cell-size and alignment; Added BoxLayout.Sven Gothel2023-04-293-56/+369
|
* GraphUI Shape: Use null rotPivot indicating unset (isZero not sufficient); ↵Sven Gothel2023-04-281-13/+17
| | | | toString() just drop no-border and no-padding.
* GraphUI Shape: Fix hasPadding() and add padding + border details to toString()Sven Gothel2023-04-281-2/+4
|
* GraphUI Add Alignment and Gap for layoutSven Gothel2023-04-282-0/+199
|
* GraphUI Shape: [add|remove]MouseListener(): Return shape for chainingSven Gothel2023-04-281-4/+6
|
* GraphUI Colors: Use pure white modulation w/ color-channel on no-action for ↵Sven Gothel2023-04-285-23/+57
| | | | original color, adjust defaults accordingly
* GraphUI Revise Padding and Border: Padding + Border belong to Shape's ↵Sven Gothel2023-04-287-42/+159
| | | | bounds. Account for both (seperately) and add border rendering to Group as well.
* GraphUI GraphShape: Apply {update->reset}GLRegion()Sven Gothel2023-04-284-4/+4
| | | | See commit 386f9652e0169b0aa7f6ead1bf230d5d67d00a38
* GraphUI GraphShape: Refine API docSven Gothel2023-04-281-1/+23
|
* GraphUI GraphShape: {update->reset}GLRegion() and reserve vertices+indices ↵Sven Gothel2023-04-284-16/+20
| | | | if (rect) border is present
* GraphUI GraphShape: createGLRegion() -> updateGLRegion(), called by ↵Sven Gothel2023-04-2012-88/+157
| | | | | | | | | | | | | | | | | | | | | | 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.
* GraphUI Button.createGLRegion(): Pre-calc Region buffer size for BaseButton ↵Sven Gothel2023-04-201-1/+14
| | | | (16) + Label-Text to avoid buffer grow
* GraphUI {Round->Base}Button, denoting perpendicular or round corners (aka ↵Sven Gothel2023-04-193-42/+66
| | | | | | | | rectangle or oval shape) - Button + BaseButton setter also pass this for chaining - Button {twoPassLabel->label}ZOffset, investigate whether z-offset still required (not if blending is enabled!) -
* GraphUI: Add BoxLayout and Margin, todo: Have GridLayout properly use Gap w/ ↵Sven Gothel2023-04-182-0/+319
| | | | Padding and alignment (Margin?) (CSS alike)
* GraphUI Padding: Use CSS alike ctor semantics, hence swizzle ctor argumentsSven Gothel2023-04-181-8/+65
|
* Graph + GraphUI: Consolidate Vertex: Drop SVertex and factory, use Vec[234]f ↵Sven Gothel2023-04-189-94/+64
| | | | | | | | | | | 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 Group.drawImpl0(): Copy List<Shape> to array and sort using ↵Sven Gothel2023-04-141-2/+7
| | | | | | | Shape.ZAscendingComparator - fixes z-order issue, as we shall do same approach as in Scene.display() - fixes mutated container issue if a Shape gets removed or added to original List
* GraphUI Container.removeShape(..): Return removed Shape, add ↵Sven Gothel2023-04-143-8/+33
| | | | removeShape(index) variant; Group.(add|remove)Shape(..) markShapeDirty() to recompute bbox and layout.
* GraphUI Shape.validate(*): Return this for chainingSven Gothel2023-04-141-2/+4
|
* GraphUI Scene: Use getRenderModeString(..) w/ sample-counts where ↵Sven Gothel2023-04-141-43/+55
| | | | applicable, restructure screenshot(..) by using nextScreenshotFile(..) - all using default tech representation
* GraphUI Scene.screenshot(): Add convenient variant to be executed on-display ↵Sven Gothel2023-04-131-0/+28
| | | | call. FontView stays open and issues a screenshot.
* GraphUI GridLayout: Also adjust potential bottom-left delta when centering ↵Sven Gothel2023-04-131-2/+3
| | | | shape to cell (like GlyphShape w/ underline)