Package com.openinventor.inventor
Class SbCylinder
java.lang.Object
com.openinventor.inventor.SbBasic
com.openinventor.inventor.SbCylinder
Class for representing a cylinder.
This class defines a simple cylinder datatype. It is used by the Open Inventor toolkit for arguments or return values.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.SbCylinder(float[] components) SbCylinder(SbCylinder copyFrom) SbCylinder(SbLine a, float r) Constructor that takes an axis and radius. -
Method Summary
Modifier and TypeMethodDescriptiongetAxis()Return the axis.floatReturn the radius.float[]getValue()SbVec3f[]Intersect line and cylinder, returning true if there is an intersection.Intersect line and cylinder, returning true if there is an intersection.voidSet the axis.voidsetRadius(float r) Set the radius.setValue(float[] components) setValue(float[] components, int startIndex) voidsetValue(SbCylinder copyFrom) voidChange the axis and radius.static SbCylinder[]toArray(long nativeArray, long length)
-
Field Details
-
array
public final float[] array
-
-
Constructor Details
-
SbCylinder
public SbCylinder(float[] components) -
SbCylinder
-
SbCylinder
Constructor that takes an axis and radius. -
SbCylinder
public SbCylinder()Default constructor. The cylinder is oriented along the Y axis and has a radius of 1.
-
-
Method Details
-
setValue
-
getValue
public float[] getValue() -
setValue
-
setValue
-
setRadius
public void setRadius(float r) Set the radius. -
toArray
-
getAxis
Return the axis. -
setAxis
Set the axis. -
setValue
Change the axis and radius. -
intersectFirst
Intersect line and cylinder, returning true if there is an intersection. -
intersect
Intersect line and cylinder, returning true if there is an intersection. -
getRadius
public float getRadius()Return the radius.
-