| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
a zero epsilon value to reduce complexity in upper math layers
|
|
|
|
| |
passing FloatUtil.EPSILON to explicit isZero(a, epsilon)
|
|
|
|
|
|
|
|
|
|
|
| |
new impl; Add isConvex*() to determine whether a polyline is convex
I had problems using the previous line2line intersection methods in my (and my son's) C++ gfxbox2 project, e.g. freefall01.
Hence I found a different solution, also using less operations:
<https://jausoft.com/cgit/cs_class/gfxbox2.git/tree/include/pixel/pixel2f.hpp#n660>
While adding intersection tests for our Delaunay (Bug 1501) .. I came across this issue again
and hence swapped the implementation.
|
| |
|
|
|
|
| |
*2d() variants
|
|
|
|
|
|
|
|
|
|
|
| |
inner-hole:=CW w/o using winding determination (might be incorrect)
This simplifies our code further and it has been validated that our polygon shoelace-algo for area >= 0 ? CCW
doesn't produce correct results with all curves.
Hence rely on given winding depending on outer-boundary and inner-hole if CDTriangulator2D.FixedWindingRule == true (default and fixed).
This also removes the more costly winding shoelace calculus,
hence Outline ctor only sets dirtyWinding:=true w/o calculating the winding.
|
|
|
|
|
|
|
|
|
|
|
|
| |
version, overcome float precision; Loop: Pass edgeType not Winding, simplify findClosestValidNeighbor() -> isValidNeighbor(); CDTriangulator2D.addCurve() enforces Winding.CCW on BOUNDARY null == loop case
Add double version of triAreaVec2() and isInCircleVec2() in VectorUtil, overcoming float precision limits
- Analysis exposed float precision limits within isInCircleVec2()
Loop: Pass edgeType not Winding, simplify findClosestValidNeighbor() -> isValidNeighbor()
- Enhance code clarity
CDTriangulator2D.addCurve() enforces Winding.CCW on BOUNDARY null == loop case
|
|
|
|
| |
copy-ctor in com.jogamp.graph.* and com.jogamp.math.*
|
| |
|
|
|
|
| |
pending setup/update of texture and image dimensions
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
-> PMVMatrix4f
Shape.setTransformMv() is called for each renderer frame and for each shape,
involving 6 Matrix4f.mul() and set*() operations.
Since mutation of shape's position, rotation or scale is less frequent
than rendering one frame (for all shapes),
it is more efficient to maintain a local Matrix4f and update it
on such single mutations.
Rendering then only needs to perform one Matrix4f.mul() operation
using this internal matrix.
+++
Also changes name from setTransformMv(PMVMatrix4f) to applyMatToMv(PMVMatrix4f),
as its name might be misleading.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
well as to extract planes for float[] vec4-shader uniforms.
commit 1040bed4ecc6f4598ea459f1073a9240583fc3c3 added AABBox -> Cube -> Frustum mapping (incomplete)
and requires Frustum.Plane.set(..) by normal and point-on-plane for distance.
Frustum.isOutside(Cube) has been added, testing all its 8-points similar to AABBox.
Further all 6 Frustum.Plane shall be extracted to Vec4f and float[],
the latter to pass the whole float[4*6] as a vec4[6] uniform array to the shader.
+++
Constructor, setter and getter have been adjusted accordingly.
Most of the loops have been unrolled.
+++
Method names to query Frustum, i.e. 'is*Outside(<Type>)'
have been reduced to 'isOutside(<Type>)'
where <Type> uniquely indenticates the purpose.
Hence only 'isSphereOutside()' is left over.
|
|
|
|
| |
AABBox into model-view Cube to Frustum.Plane for culling (cpu) and clipping (gpu)
|
|
|
|
|
|
|
|
|
|
|
| |
orientation in API doc
br, tr wasn't sufficient as in commit d778889f36bd6bee999ceb502c5f0ce265b014bf
while working on Frustum, as it doesn't properly reflect axis order not z.
Hence going back to 'low' and 'high' semantics,
but using same length identifier and emphasizing far (lo) < near (hi)
of our model-view coordinate system.
|
|
|
|
| |
and scale2(float, float, float)
|
|
|
|
| |
Unroll getRayIntersection()'s 'find candidate planes'
|
| |
|
|
|
|
| |
expansion
|
|
|
|
| |
v_in', user can simply get the desired matrix and apply its mulVec*(..) operation
|
|
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.
|