aboutsummaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* FloatUtil.abs(a): Mark as deprecated, use Math.abs(a) directly. We assume it ↵Sven Gothel2023-09-046-15/+22
| | | | | | | | | | | | | | | | is an intrinsic + branch-less implementation Expected implementation is - return Float.intBitsToFloat(Float.floatToRawIntBits(a) & 0x7fffffff); replacing old implementation - return (a <= 0.0F) ? 0.0F - a : a; .. also market as @IntrinsicCandidate Hence we shall leave it to the JRE core-lib implementation...
* 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-0410-24/+17
| | | | 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-049-54/+243
| | | | 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
|
* FloatUtil.isEqual(..): Rename raw {isEqual->isEqualRaw}(a,b) varianr w/o ↵Sven Gothel2023-09-0311-59/+121
| | | | | | EPSILON; Add isEqual(a,b) w/ default EPSILON; Use it where applicable Also add isEqual2(a,b) w/o corner cases (NaN, Inf) used for comparison in Graph Outline, OutlineShape and later GraphUI Shape.
* GraphUI Scene: Generalize its interface PMVMatrixSetup and usage of its ↵Sven Gothel2023-09-0310-229/+188
| | | | 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-0313-31/+84
| | | | [1..8]; Add clarity in Region; Demos CommandlineOptions adds actual graphAASamples set and utilized
* GraphUI Demos: Proper use of CommandlineOptionsSven Gothel2023-09-024-34/+18
|
* Demos: CommandlineOptions: Add total_duration command line option '-duration ↵Sven Gothel2023-09-021-14/+19
| | | | <floar>' in seconds
* PMVMatrix.gluPerspective(): Redfine angle in radians instead of degrees ** ↵Sven Gothel2023-09-0219-32/+53
| | | | | | | | 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
* Graph Font + Glyph: Fix whitespace definition: Include 'no original ↵Sven Gothel2023-09-012-20/+26
| | | | | | | | | | | | | | underlying shape' and add API doc Regression was introduced with commit 920e529516bb264f04138ed1caca80d4925e3773 'Robust detetection and API definition of non-contour/whitespace Glyphs'. Issue was mistaken a glyph as undefined if not having an underlying shape, which is true for some fonts (e.g. 'space'). +++ Also Use post table's name if no underlying shape exists.
* GraphUI Demo: Rename UISceneDemoU01a -> UIGraphDemoU01a, not using GraphUI's ↵Sven Gothel2023-09-011-4/+24
| | | | Scene but manual GLEventListener etc, add a few Glyph tests
* GraphUI Demo FontView01: Fix '-showUnderline', i.e. glyphListener shall use ↵Sven Gothel2023-08-281-1/+1
| | | | the last element in container, the GlyphShape
* GraphUI Demo FontView01: Enhance usability and refactor: Add left-column ↵Sven Gothel2023-08-281-78/+206
| | | | | | | | | | | | | | | | | | | | glyphSymbol number, mouse-wheel scrolling, Fitting the font info, .. - Add mouse-wheel scrolling, for one-line and with control for one page. - Add left-column glyphSymbol number, for orientation while scrolling - Fitting the font info, i.e. consider width + height Refactoring further isolated the addGlyphs(..) functionality in same method, etc. Used to test Graph's capabilitry to properly read, detect and visualize certain fonts. Previous Graph fixes were triggered by this procedure, i.e. commits - 733cc5272cfed10fa07b707e29fd756f44581508 - 920e529516bb264f04138ed1caca80d4925e3773 - 7fd51917b0cc85c3dc3d07592093a62b213d1ea5 Further the proper detection of non-contour/whitespace allows FontView to skip them and only show usably Glyphs without noise.
* Graph Font: Make TypecastRenderer.DEBUG package private to be used by ↵Sven Gothel2023-08-281-1/+1
| | | | TypecastFont
* 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-289-71/+178
| | | | | | non-contour/whitespace Glyphs (detect and allow to skip 'em) We also drop shapes for both, but for id 0 (unknown).
* Graph Loop: Make initFromPolyline() and locateClosestVertex() more robust, ↵Sven Gothel2023-08-284-12/+34
| | | | | | report error but do not crash. This behavior has been evaluated with a few fonts and the WIP FontView01 demo application.
* UISceneDemo03: Detail demo description, add blog entrySven Gothel2023-08-271-3/+7
|
* GraphUI Demo: UISceneDemo03: Add optional audio (only) via '-audio <URL or ↵Sven Gothel2023-08-271-4/+108
| | | | file-path>' using our GLMediaPlayer (FFmpeg + JOAL/OpenAL)
* 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-277-781/+1336
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
* Add TestVec3f01NOUI: This test shall be enhanced, only priliminary angle ↵Sven Gothel2023-08-271-0/+137
| | | | tests for now
* AABBox: Fix intersects2DRegion(..), add resize{Height, Width}(..) and AABBox ↵Sven Gothel2023-08-271-4/+57
| | | | | | | | | ctor using Vec3f low and high intersects2DRegion(..) got the passed width and height wrong, i.e. given object low position >= this-low position and given object high position including width/height <= this-high position is required to match for intersection.
* Vec3f: Add UNIX_X and UNIX_X_NEG, enhance API docSven Gothel2023-08-271-2/+4
|
* Quaternion: Add rotateByAngleNormalAxis(..) variant using Vec3f axisSven Gothel2023-08-271-1/+18
|
* GraphUI: Use thread-save and lock-free CopyOnWriteArrayList for List<Shape>, ↵Sven Gothel2023-08-272-4/+4
| | | | allowing off-thread mutation
* AABBox: Add set(AABBox)Sven Gothel2023-08-251-0/+13
|
* 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
* Vec[234]f: Add scale(Vec[234]f s) variant for convenienceSven Gothel2023-08-233-0/+9
|
* TestSWTAccessor02NewtGLWindow: Use lambda for SWTAccessor.invokeOnOSTKThread(..)Sven Gothel2023-08-231-4/+5
|
* Demos: Use Runnable lambda for window.destroy() off-thread and use ↵Sven Gothel2023-08-2310-57/+37
| | | | key-symbols F4, ESC and Q to trigger off-thread window.destroy()
* UISceneDemo03b: Add a little more customization ..Sven Gothel2023-08-191-6/+23
|
* Bug 1310: Reset GLJPanel states @ dispose(..) and always reshapeImpl(..) @ ↵v2.5.0Sven Gothel2023-08-181-7/+30
| | | | | | | | | addNotify(), leading to proper initialization sequence when re-adding panel. The proper initialization sequence subsequently also leads to proper glViewport initialization, see commit d17d807a76ba9cb940542264fcad9cf71c7ec585 No side-effects expected, just ensuring same code-path compared to initial addNotify().
* Bug 1310: Detect missing glViewport(..) on Windows before ↵Sven Gothel2023-08-181-2/+24
| | | | | | | | | | | | | | | | | GLEventListener.reshape(..) when re-adding GLJPanel When re-adding GLJPanel on Windows glViewport() is not called through - GLJPanel.Updater.display() - GLDrawableHelper.reshape() - GLDrawableHelper.setViewportAndClear() Instead the following sequence is called due to sendReshape == false: - GLJPanel.Updater.display() - GLDrawableHelper.display() ** missing glViewport(..) ** This bug is not visible on X11 or MacOS since the glViewport is only set to a different user value on Windows ...
* Demos: ..demos.graph.ui.util.GraphUIDemoArgs -> ..demos.util.CommandlineOptionsSven Gothel2023-08-1316-34/+33
|
* GraphUIDemoArgs: Issue GLProfile.initSingleton() once in static init block, ↵Sven Gothel2023-08-132-1/+5
| | | | | | ensuring JOGL is completely initialized Noteable: On MacOS 13.1 (aarch64) UISceneDemo20 won't show the window if NEWT is initialized before JOGL core via GLProfile.initSingleton().
* UISceneDemo20: Fix info/debug text title GPUUISceneGLListener0A -> UISceneDemo20Sven Gothel2023-08-131-7/+8
|
* Minor cleanup of imports, etc: FBObject, GLContext*, Texture, ..Sven Gothel2023-08-137-58/+36
| | | | TODO: Full cleanup perhaps
* Texture ctor w/ external textureID: Pass `ownsTextureID` where true hands ↵Sven Gothel2023-08-133-17/+48
| | | | | | | | | 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.
* GraphUIDemoArgs: Add GL4 coreSven Gothel2023-08-131-0/+2
|
* Demos: Add main() to GearsES2, .. allowing to be used for simple bringup testsSven Gothel2023-08-133-12/+166
|
* Animator*: Add ctor variants passing modeBits directly, i.e. enable/disable ↵Sven Gothel2023-08-1369-741/+941
| | | | AWT rendering thread support. Adopt it in tests and demos
* FontViewListener01/TestTextRendererNEWT21: Use 30 pixelPerCell (total w/ ↵Sven Gothel2023-08-121-10/+21
| | | | gap) for test case to compare pixel-by-pixel