Package org.robwork.sdurw_geometry
Class ConvexHull3D
- java.lang.Object
-
- org.robwork.sdurw_geometry.ConvexHull3D
-
- Direct Known Subclasses:
QHull3D
public class ConvexHull3D extends java.lang.Object
interface for convexhull calculators on 3d point sets
-
-
Constructor Summary
Constructors Constructor Description ConvexHull3D(long cPtr, boolean cMemoryOwn)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
delete()
static long
getCPtr(ConvexHull3D obj)
double
getMinDistInside(Vector3D vertex)
If the vertex is inside the convex hull the minimum distance
to any of the half-spaces of the hull is returned.double
getMinDistOutside(Vector3D vertex)
If the vertex is outside the convex hull the minimum distance
to the convex hull is returned.boolean
isInside(Vector3D vertex)
test if the given vertex is inside the convex hullvoid
rebuild(SWIGTYPE_p_std__vectorT_rw__math__Vector3DT_double_t_t vertices)
rebuilts the hullPlainTriMeshN1Ptr
toTriMesh()
create a plain trimesh from the hull facets
-
-
-
Method Detail
-
getCPtr
public static long getCPtr(ConvexHull3D obj)
-
delete
public void delete()
-
rebuild
public void rebuild(SWIGTYPE_p_std__vectorT_rw__math__Vector3DT_double_t_t vertices)
rebuilts the hull- Parameters:
vertices
-
-
isInside
public boolean isInside(Vector3D vertex)
test if the given vertex is inside the convex hull
-
getMinDistInside
public double getMinDistInside(Vector3D vertex)
If the vertex is inside the convex hull the minimum distance
to any of the half-spaces of the hull is returned. If its not inside
0 is returned.- Parameters:
vertex
-- Returns:
- minimum distance to vertex
-
getMinDistOutside
public double getMinDistOutside(Vector3D vertex)
If the vertex is outside the convex hull the minimum distance
to the convex hull is returned. If its not outside 0 is returned.- Parameters:
vertex
-- Returns:
- minimum distance to vertex
-
toTriMesh
public PlainTriMeshN1Ptr toTriMesh()
create a plain trimesh from the hull facets- Returns:
- the hull facets as a plain triangle mesh with normal information
-
-