Package org.robwork.sdurw_geometry
Class ConvexHull3DPtr
- java.lang.Object
-
- org.robwork.sdurw_geometry.ConvexHull3DPtr
-
public class ConvexHull3DPtr extends java.lang.Object
Ptr stores a pointer and optionally takes ownership of the value.
-
-
Constructor Summary
Constructors Constructor Description ConvexHull3DPtr()
Default constructor yielding a NULL-pointer.ConvexHull3DPtr(long cPtr, boolean cMemoryOwn)
ConvexHull3DPtr(ConvexHull3D ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ConvexHull3D
__ref__()
Dereferencing operator.ConvexHull3DCPtr
cptr()
void
delete()
ConvexHull3D
deref()
The pointer stored in the object.boolean
equals(ConvexHull3D p)
static long
getCPtr(ConvexHull3DPtr obj)
ConvexHull3D
getDeref()
Member access operator.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 hullboolean
isNull()
checks if the pointer is nullboolean
isShared()
check if this Ptr has shared ownership or none
ownershipvoid
rebuild(SWIGTYPE_p_std__vectorT_rw__math__Vector3DT_double_t_t vertices)
rebuilts the hullPlainTriMeshN1Ptr
toTriMesh()
create a plain trimesh from the hull facets
-
-
-
Constructor Detail
-
ConvexHull3DPtr
public ConvexHull3DPtr(long cPtr, boolean cMemoryOwn)
-
ConvexHull3DPtr
public ConvexHull3DPtr()
Default constructor yielding a NULL-pointer.
-
ConvexHull3DPtr
public ConvexHull3DPtr(ConvexHull3D ptr)
Do not take ownership of ptr.
ptr can be null.
The constructor is implicit on purpose.
-
-
Method Detail
-
getCPtr
public static long getCPtr(ConvexHull3DPtr obj)
-
delete
public void delete()
-
deref
public ConvexHull3D deref()
The pointer stored in the object.
-
__ref__
public ConvexHull3D __ref__()
Dereferencing operator.
-
getDeref
public ConvexHull3D getDeref()
Member access operator.
-
equals
public boolean equals(ConvexHull3D p)
-
isShared
public boolean isShared()
check if this Ptr has shared ownership or none
ownership- Returns:
- true if Ptr has shared ownership, false if it has no ownership.
-
isNull
public boolean isNull()
checks if the pointer is null- Returns:
- Returns true if the pointer is null
-
cptr
public ConvexHull3DCPtr cptr()
-
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
-
-