BBox Type
An immutable 3D-bounding-box. This implementation guarantees the box to be always valid. That means the Min X, Y and Z values are always smaller or equal than the respective Max values. The X, Y and Z axes are also called Width, Depth and Height3D. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
Record fields
Record Field |
Description
|
Full Usage:
MaxX
Field type: float
|
|
Full Usage:
MaxY
Field type: float
|
|
Full Usage:
MaxZ
Field type: float
|
|
Full Usage:
MinX
Field type: float
|
|
Full Usage:
MinY
Field type: float
|
|
Full Usage:
MinZ
Field type: float
|
|
Instance members
Instance member |
Description
|
Full Usage:
this.AsString
Returns: string
|
Format BoundingBox into string with nice floating point number formatting of size and position. But without full type name as in bbox.ToString()
|
|
Returns the bottom of the Box as a Counter-Clockwise array of 4 Points. Starting at MinPt. Point 0, 1, 2 and 3. Last and first point are NOT the same. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns the bottom of the Box as a Counter-Clockwise array of 5 Points, starting at MinPt. Starting at MinPt. Point 0, 1, 2, 3 and again 0. Last and first point are the same. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
The center of this 3D-bounding-box.
|
|
Returns true if this 3D-bounding-box is inside or exactly on the other bounding Box.
|
|
|
Full Usage:
this.Depth
Returns: float
Modifiers: inline |
The size in Y direction, same as member box.SizeY.
|
|
The diagonal 3D vector of this 3D-bounding-box. From MinPnt to MaxPnt.
|
|
Returns the X aligned Edge from point 0 to 1.
|
|
Returns the Y aligned Edge from point 0 to 3.
|
|
Returns the Z aligned Edge from point 0 to 4.
|
|
Returns the Y aligned Edge from point 1 to 2.
|
|
Returns the Z aligned Edge from point 1 to 5.
|
|
Returns the Z aligned Edge from point 2 to 6.
|
|
Returns the X aligned Edge from point 3 to 2.
|
|
Returns the Z aligned Edge from point 3 to 7.
|
|
Returns the X aligned Edge from point 4 to 5.
|
|
Returns the Y aligned Edge from point 4 to 7.
|
|
Returns the Y aligned Edge from point 5 to 6.
|
|
Returns the X aligned Edge from point 7 to 6.
|
|
Returns the 12 Edges of this 3D-bounding-box as an array of 12 Lines. Pair is this order: 0-1, 1-2, 3-2, 0-3, 0-4, 1-5, 2-6, 3-7, 4-5, 5-6, 7-6, 4-7 Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
Full Usage:
this.EvaluateAt
Parameters:
float
yParameter : float
zParameter : float
Returns: Pnt
Modifiers: inline |
Evaluate a X, Y and Z parameter of this 3D-bounding-box. 0.0, 0.0, 0.0 returns the MinPnt. 1.0, 1.0, 1.0 returns the MaxPnt.
|
Full Usage:
this.Expand
Parameters:
float
yDist : float
zDist : float
Returns: BBox
Modifiers: inline |
Returns a 3D-bounding-box expanded by a distance for X, Y and Z-axis each. Does check for underflow if distance is negative and raises EuclidException.
|
|
Returns a 3D-bounding-box expanded by distance. Does check for underflow if distance is negative and raises EuclidException.
|
|
Returns a 3D-bounding-box expanded by a distance. If expansion is negative it shrinks the Box. It also makes sure that there is no underflow. When the negative expansion is bigger than the size, Min and Max values will be both in the middle from where they were before.
|
Full Usage:
this.ExpandSave
Parameters:
float
yDist : float
zDist : float
Returns: BBox
Modifiers: inline |
Returns a 3D-bounding-box expanded by a distance for X, Y and Z-axis each. If expansion is negative it shrinks the Box. It also makes sure that there is no underflow. When the negative expansion is bigger than the size, Min and Max values will be both in the middle from where they were before.
|
Full Usage:
this.ExpandXaxis
Parameters:
float
endDist : float
Returns: BBox
Modifiers: inline |
Returns a 3D-bounding-box expanded only in X direction by different distance for start(minX) and end (maxX). Does check for underflow if distance is negative and raises EuclidException.
|
Full Usage:
this.ExpandYaxis
Parameters:
float
endDist : float
Returns: BBox
Modifiers: inline |
Returns a 3D-bounding-box expanded only in Y direction by different distance for start(minY) and end (maxY). Does check for underflow if distance is negative and raises EuclidException.
|
Full Usage:
this.ExpandZaxis
Parameters:
float
endDist : float
Returns: BBox
Modifiers: inline |
Returns a 3D-bounding-box expanded only in Z direction by different distance for start(minZ) and end (maxZ). Does check for underflow if distance is negative and raises EuclidException.
|
Full Usage:
this.Height3D
Returns: float
Modifiers: inline |
The size in Z direction, same as member box.SizeZ.
|
|
|
|
Test if 3D-bounding-boxes are only touching each other from the Outside within a given tolerance.
|
|
The point where X, Y and Z are the maximum values.
|
|
The point where X, Y and Z are the minimum values.
|
|
Returns true if the two 3D-bounding-boxes do overlap more than a given tolerance distance. Returns false if the two 3D-bounding-boxes are just touching. Also returns true if one box is completely inside the other. Also returns true if one box is completely surrounding the other.
|
|
Returns true if the two 3D-bounding-boxes do overlap or touch. Also returns true if one box is completely inside the other. Also returns true if one box is completely surrounding the other.
|
|
Returns the bottom corners of this 3D-bounding-box in Counter-Clockwise order, starting at MinPt. Then the top corners staring above MinPt. Returns an array of 8 Points. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
Returns point 0 of this 3D-bounding-box, same as member box.MinPnt. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 1 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 2 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 3 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 4 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 5 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 6 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns point 7 of this 3D-bounding-box. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Full Usage:
this.SizeX
Returns: float
Modifiers: inline |
The size in X direction, same as member box.Width.
|
Full Usage:
this.SizeY
Returns: float
Modifiers: inline |
The size in Y direction, same as member box.Depth.
|
Full Usage:
this.SizeZ
Returns: float
Modifiers: inline |
The size in Z direction, same as member box.Height3D.
|
|
Returns the bottom of the Box as a Counter-Clockwise array of 4 Points. Staring at point 4 then 5, 6 and 7. Last and first point are NOT the same. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
Returns the bottom of the Box as a Counter-Clockwise array of 5 Points. Starting point 4 then 5, 6, 7 and again 4. Last and first point are the same. Z-Axis Y-Axis (Depth) ^ / | 7 / 6 MaxPt | +---------------+ | /| / /| | / | / / | 4 |/ | / 5 / | +---------------+ | | |/ | | | +-----------|---+ | / 3 | / 2 | / | / |/ |/ +---------------+----> X-Axis (Width) 0 MinPt 1
|
|
|
|
|
Full Usage:
this.Volume
Returns: float
Modifiers: inline |
Returns the volume of this 3D-bounding-box.
|
Full Usage:
this.Width
Returns: float
Modifiers: inline |
The size in X direction, same as member box.SizeX.
|
|
Returns the 2D part of this 3D-bounding-box as a bounding rectangle (BRect).
|
Static members
Static member |
Description
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Full Usage:
BBox.createUnchecked (minX, minY, minZ, maxX, maxY, maxZ)
Parameters:
float
minY : float
minZ : float
maxX : float
maxY : float
maxZ : float
Returns: BBox
Modifiers: inline |
Does not verify the order of min and max values.
|
|
|
|
Returns true if the two a 3D-bounding-boxes do overlap more than a given tolerance distance. Returns false if the two a 3D-bounding-boxes are just touching. Also returns true if one box is completely inside the other. Also returns true if one box is completely surrounding the other.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|