Package org.robwork.sdurw_geometry
Class Primitive
- java.lang.Object
-
- org.robwork.sdurw_geometry.GeometryData
-
- org.robwork.sdurw_geometry.Primitive
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.robwork.sdurw_geometry.GeometryData
GeometryData.GeometryType
-
-
Constructor Summary
Constructors Constructor Description Primitive(long cPtr, boolean cMemoryOwn)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TriMeshPtr
createMesh(int resolution)
make a trimesh from this primitive.void
delete()
static long
getCPtr(Primitive obj)
Q
getParameters()
get the parameters that define this primitiveTriMeshPtr
getTriMesh()
Note: primitives allways return a new trimeshTriMeshPtr
getTriMesh(boolean forceCopy)
Note: primitives allways return a new trimeshboolean
isConvex()
test if this geometry data is convexboolean
isInside(Vector3D point)
test if a point is on the border or inside this primitivevoid
setParameters(Q q)
set the parameters that define this primitive-
Methods inherited from class org.robwork.sdurw_geometry.GeometryData
getCPtr, getType, toString
-
-
-
-
Method Detail
-
getCPtr
public static long getCPtr(Primitive obj)
-
delete
public void delete()
- Overrides:
delete
in classGeometryData
-
getTriMesh
public TriMeshPtr getTriMesh(boolean forceCopy)
Note: primitives allways return a new trimesh- Overrides:
getTriMesh
in classGeometryData
- Returns:
- TriMesh representation of this GeometryData
-
getTriMesh
public TriMeshPtr getTriMesh()
Note: primitives allways return a new trimesh- Overrides:
getTriMesh
in classGeometryData
- Returns:
- TriMesh representation of this GeometryData
-
createMesh
public TriMeshPtr createMesh(int resolution)
make a trimesh from this primitive. Use granularity to
specify minimum number of line segments a half circle is split into- Parameters:
resolution
- [in]
-
getParameters
public Q getParameters()
get the parameters that define this primitive
-
setParameters
public void setParameters(Q q)
set the parameters that define this primitive
-
isConvex
public boolean isConvex()
Description copied from class:GeometryData
test if this geometry data is convex- Overrides:
isConvex
in classGeometryData
- Returns:
- true if convex
-
isInside
public boolean isInside(Vector3D point)
test if a point is on the border or inside this primitive
-
-