[mxcad_3d API documentation](../README. md)/Mx3dGeBendBox
Class: Mx3dGeBndBox
Represents a bounding box in three-dimensional space.
Provide constructors and methods for manipulating bounding boxes, including setting, updating, transforming, and checking. The bounding box class is mainly used for calculating and manipulating bounding boxes in space, and is typically used in scenarios such as collision detection and spatial segmentation.
Hierarchy
↳
Mx3dGeBndBox
Table of contents
Constructors
Methods
- AddBndBox
- AddDir
- AddPoint
- AddPointDir
- CornerMax
- CornerMin
- Distance
- Enlarge
- FinitePart
- GetGap
- HasFinitePart
- IsOpen
- IsOpenXmax
- IsOpenXmin
- IsOpenYmax
- IsOpenYmin
- IsOpenZmax
- IsOpenZmin
- IsOutBndBox
- IsOutPPD
- IsOutPoint
- IsOutTBT
- IsThin
- IsVoid
- IsWhole
- IsXThin
- IsYThin
- IsZThin
- OpenXmax
- OpenXmin
- OpenYmax
- OpenYmin
- OpenZmax
- OpenZmin
- Set
- SetGap
- SetVoid
- SetWhole
- SquareExtent
- Transformed
- Update
Constructors
constructor
• new Mx3dGeBndBox()
Construct an empty bounding box by default.
Overrides
Mx3dGeObject.constructor
• new Mx3dGeBndBox(theMin
, theMax
)
Construct a bounding box using the given minimum and maximum points.
Parameters
Name | Type | Description |
---|---|---|
TheMin | [Mx3dGePoint] (Mx3dGePoint. md) | The minimum point of the bounding box |
TheMax | [Mx3dGePoint] (Mx3dGePoint. md) | The maximum point of the bounding box |
Overrides
Mx3dGeObject.constructor
Methods
AddBndBox
▸ AddBndBox(Other
): void
Parameters
Name | Type |
---|---|
Other | Mx3dGeBndBox |
Returns
void
AddDir
▸ AddDir(D
): void
Parameters
Name | Type |
---|---|
D | Mx3dGeDir |
Returns
void
AddPoint
▸ AddPoint(P
): void
Parameters
Name | Type |
---|---|
P | Mx3dGePoint |
Returns
void
AddPointDir
▸ AddPointDir(P
, D
): void
Parameters
Name | Type |
---|---|
P | Mx3dGePoint |
D | Mx3dGeDir |
Returns
void
CornerMax
▸ CornerMax(): Mx3dGePoint
Returns
CornerMin
▸ CornerMin(): Mx3dGePoint
Returns
Distance
▸ Distance(Other
): number
Parameters
Name | Type |
---|---|
Other | Mx3dGeBndBox |
Returns
number
Enlarge
▸ Enlarge(Tol
): void
Parameters
Name | Type |
---|---|
Tol | number |
Returns
void
FinitePart
▸ FinitePart(): Mx3dGeBndBox
Returns
GetGap
▸ GetGap(): number
Returns
number
HasFinitePart
▸ HasFinitePart(): boolean
Returns
boolean
IsOpen
▸ IsOpen(): boolean
Returns
boolean
IsOpenXmax
▸ IsOpenXmax(): boolean
Returns
boolean
IsOpenXmin
▸ IsOpenXmin(): boolean
Returns
boolean
IsOpenYmax
▸ IsOpenYmax(): boolean
Returns
boolean
IsOpenYmin
▸ IsOpenYmin(): boolean
Returns
boolean
IsOpenZmax
▸ IsOpenZmax(): boolean
Returns
boolean
IsOpenZmin
▸ IsOpenZmin(): boolean
Returns
boolean
IsOutBndBox
▸ IsOutBndBox(Other
): boolean
Parameters
Name | Type |
---|---|
Other | Mx3dGeBndBox |
Returns
boolean
▸ IsOutBndBox(Other
, T
): boolean
Parameters
Name | Type |
---|---|
Other | Mx3dGeBndBox |
T | Mx3dGeTrsf |
Returns
boolean
IsOutPPD
▸ IsOutPPD(P1
, P2
, D
): boolean
Parameters
Name | Type |
---|---|
P1 | Mx3dGePoint |
P2 | Mx3dGePoint |
D | Mx3dGeDir |
Returns
boolean
IsOutPoint
▸ IsOutPoint(P
): boolean
Parameters
Name | Type |
---|---|
P | Mx3dGePoint |
Returns
boolean
IsOutTBT
▸ IsOutTBT(T1
, Other
, T2
): boolean
Parameters
Name | Type |
---|---|
T1 | Mx3dGeTrsf |
Other | Mx3dGeBndBox |
T2 | Mx3dGeTrsf |
Returns
boolean
IsThin
▸ IsThin(tol
): boolean
Parameters
Name | Type |
---|---|
tol | number |
Returns
boolean
IsVoid
▸ IsVoid(): boolean
Returns
boolean
IsWhole
▸ IsWhole(): boolean
Returns
boolean
IsXThin
▸ IsXThin(tol
): boolean
Parameters
Name | Type |
---|---|
tol | number |
Returns
boolean
IsYThin
▸ IsYThin(tol
): boolean
Parameters
Name | Type |
---|---|
tol | number |
Returns
boolean
IsZThin
▸ IsZThin(tol
): boolean
Parameters
Name | Type |
---|---|
tol | number |
Returns
boolean
OpenXmax
▸ OpenXmax(): void
Returns
void
OpenXmin
▸ OpenXmin(): void
Returns
void
OpenYmax
▸ OpenYmax(): void
Returns
void
OpenYmin
▸ OpenYmin(): void
Returns
void
OpenZmax
▸ OpenZmax(): void
Returns
void
OpenZmin
▸ OpenZmin(): void
Returns
void
Set
▸ Set(P
, D
): void
Set the direction of the bounding box.
Parameters
Name | Type | Description |
---|---|---|
P | [Mx3dGePoint] (Mx3dGePoint. md) | The reference point of the bounding box |
D | [Mx3dGeDir] (Mx3dGeDir. md) | The direction of the bounding box |
Returns
void
SetGap
▸ SetGap(Tol
): void
Parameters
Name | Type |
---|---|
Tol | number |
Returns
void
SetVoid
▸ SetVoid(): void
Set the bounding box to an invalid state (empty bounding box).
Returns
void
SetWhole
▸ SetWhole(): void
Set the bounding box to contain the entire space.
Returns
void
SquareExtent
▸ SquareExtent(): number
Returns
number
Transformed
▸ Transformed(T
): Mx3dGeBndBox
Parameters
Name | Type |
---|---|
T | Mx3dGeTrsf |
Returns
Update
▸ Update(aXmin
, aYmin
, aZmin
, aXmax
, aYmax
, aZmax
): void
Parameters
Name | Type |
---|---|
aXmin | number |
aYmin | number |
aZmin | number |
aXmax | number |
aYmax | number |
aZmax | number |
Returns
void