Package com.ardorcraft.voxel
Class TriangleAABBIntersection
java.lang.Object
com.ardorcraft.voxel.TriangleAABBIntersection
ported from: http://jgt.akpeters.com/papers/AkenineMoller01/tribox.html
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic final boolean
intersect
(double cx, double cy, double cz, ReadOnlyVector3 extent, MeshVoxelationContext.Triangle triangle) Test if Triangle and AABB instersects Will also set triangle.normalstatic final boolean
intersect
(ReadOnlyVector3 center, ReadOnlyVector3 extent, MeshVoxelationContext.Triangle triangle)
-
Constructor Details
-
TriangleAABBIntersection
public TriangleAABBIntersection()
-
-
Method Details
-
intersect
public static final boolean intersect(ReadOnlyVector3 center, ReadOnlyVector3 extent, MeshVoxelationContext.Triangle triangle) -
intersect
public static final boolean intersect(double cx, double cy, double cz, ReadOnlyVector3 extent, MeshVoxelationContext.Triangle triangle) Test if Triangle and AABB instersects Will also set triangle.normal- Parameters:
cx
- - AABB center x valuecy
- - AABB center x valuecz
- - AABB center x valueextent
- - AABB extent of sidestriangle
- the triangle to test- Returns:
- true if intersecting
-