BoundingBox

Overview

BoundingBox is a class in Aspose.3D FOSS for Java. Inherits from: Struct<BoundingBox>, Serializable.

The axis-aligned bounding box /

This class provides 27 methods for working with BoundingBox objects in Java programs. Available methods include: BoundingBox, clone, contains, copyFrom, equals, fromGeometry, getCenter, getExtent, getInfinite, getMaximum, getMinimum, getNull, and 7 additional methods. All public members are accessible to any Java application after installing the Aspose.3D FOSS for Java package. Properties: center, extent, infinite, maximum, minimum, null, and 1 more.

Properties

NameTypeAccessDescription
nullBoundingBoxReadThe null bounding box
/
infiniteBoundingBoxReadThe infinite bounding box
/
extentBoundingBoxExtentReadGets the extent of the bounding box.
minimumVector3ReadThe minimum corner of the bounding box
@return The minimum corner of the bounding box
/
maximumVector3ReadThe maximum corner of the bounding box
@return The maximum corner of the bounding box
/
sizeVector3ReadThe size of the bounding box
@return The size of the bounding box
/
centerVector3ReadThe center of the bounding box.

Methods

SignatureDescription
getNull()BoundingBoxThe null bounding box
/
getInfinite()BoundingBoxThe infinite bounding box
/
BoundingBox(minimum: Vector3, maximum: Vector3)Initialize a finite bounding box with given minimum and maximum corner
@param minimum The minimum corner
@param maximum The maximum corner
/
BoundingBox()Initializes a new instance of the BoundingBox.
BoundingBox(minimum: FVector3, maximum: FVector3)Initialize a finite bounding box with given minimum and maximum corner
@param minimum The minimum corner
@param maximum The maximum corner
/
BoundingBox(minX: double, minY: double, minZ: double, maxX: double, maxY: double, maxZ: double)Initialize a finite bounding box with given minimum and maximum corner
@param minX The minimum corner’s X
@param minY The minimum corner’s Y
@param minZ The minimum corner’s Z
@param maxX The maxi
fromGeometry(geometry: Geometry)BoundingBoxConstruct a bounding box from given geometry
@param geometry The geometry to calculate bounding box
@return The bounding box of given geometry
/
getExtent()BoundingBoxExtentGets the extent of the bounding box.
getMinimum()Vector3The minimum corner of the bounding box
@return The minimum corner of the bounding box
/
getMaximum()Vector3The maximum corner of the bounding box
@return The maximum corner of the bounding box
/
scale()doubleCalculates the absolute largest coordinate value of any contained point.
getSize()Vector3The size of the bounding box
@return The size of the bounding box
/
getCenter()Vector3The center of the bounding box.
merge(pt: Vector4)Merge current bounding box with given point
@param pt The point to merge
/
merge(pt: Vector3)Merge current bounding box with given point
@param pt The point to merge
/
merge(pt: FVector3)Merge current bounding box with given point
@param pt The point to merge
/
merge(x: double, y: double, z: double)Merge current bounding box with given point
@param x The point to be merged into the bounding box
@param y The point to be merged into the bounding box
@param z The point to be merged into the boun
merge(bb: BoundingBox)Merges the new box into the current bounding box.
mul(bbox: BoundingBox, mat: Matrix4)BoundingBoxOperator overloading for multiply, new bounding box’s minimum and maximum corner will be transformed by the matrix.
toString()StringGets the string representation of the bounding box.
equals(obj: Object)booleanDetermines if two objects are equal
@param obj The object to compare
@return true if two objects are equal
/
overlapsWith(box: BoundingBox)booleanCheck if current bounding box overlaps with specified bounding box.
contains(p: Vector3)booleanCheck if the point p is inside the bounding box
@param p The point to test
@return True if the point is inside the bounding box
/
contains(bbox: BoundingBox)booleanThe bounding box to check if it’s inside current bounding box.
clone()BoundingBoxDescription copied from interface: Struct
@return cloned instance
/
copyFrom(src: BoundingBox)Description copied from interface: Struct
@param src source instance to copy
/
hashCode()intReturns the hash code for this instance
@return The hash code of the bounding box
/

See Also

 English