Package com.openinventor.inventor
Class SbBox4i32
java.lang.Object
com.openinventor.inventor.SbBasic
com.openinventor.inventor.SbBox4i32
4D box class.
4D box which has planes parallel to the major axes and is specified by two points on a diagonal. Bounds are included in left and included in right, [min, max]. The bbox ((0, 0, 0, 0), (0, 0, 0, 0)) contains the single point (0, 0, 0, 0).
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanvoidExtends this box (if necessary) to contain the specified point.getMax()Returns the maximum point of the box.getMin()Returns the minimum point of the box.getSize()Gets box size.int[]getValue()booleanReturns true if the specified point intersects this box.booleanisEmpty()Returns true if the box is empty, and false otherwise.voidMakes an empty box.setValue(int[] components) setValue(int[] components, int startIndex) voidstatic SbBox4i32[]toArray(long nativeArray, long length)
-
Field Details
-
array
public final int[] array
-
-
Constructor Details
-
SbBox4i32
-
SbBox4i32
public SbBox4i32(int[] components) -
SbBox4i32
Constructor for a 4D integer32 box. m_min and m_max are the corners of the diagonal that define the box. -
SbBox4i32
public SbBox4i32()Constructor for a 4D integer32 box. The box is initially empty.
-
-
Method Details
-
setValue
-
setValue
-
setValue
-
getValue
public int[] getValue() -
extendBy
Extends this box (if necessary) to contain the specified point. -
toArray
-
intersect
Returns true if the specified point intersects this box. -
getMin
Returns the minimum point of the box. The minimum point is the corner of the box with the lowest X, Y, Z and W values. -
getMax
Returns the maximum point of the box. The maximum point is the corner of the box with the highest X, Y, Z and W values. -
isEmpty
public boolean isEmpty()Returns true if the box is empty, and false otherwise. Note: Setting the box to all zeros does not make it "empty". Use themakeEmpty()method. (This method only returns true if the maximum X value is less than the minimum X value.) -
equals
-
getSize
Gets box size. -
makeEmpty
public void makeEmpty()Makes an empty box.
-