Ark Server API (ASA) - Wiki
|
#include <BoxSphereBounds.h>
Public Types | |
using | FReal = T |
Static Public Member Functions | |
static FORCEINLINE bool | SpheresIntersect (const TBoxSphereBounds< T, TExtent > &A, const TBoxSphereBounds< T, TExtent > &B, TExtent Tolerance=UE_KINDA_SMALL_NUMBER) |
static FORCEINLINE bool | BoxesIntersect (const TBoxSphereBounds< T, TExtent > &A, const TBoxSphereBounds< T, TExtent > &B) |
Public Attributes | |
TVector< T > | Origin |
TVector< TExtent > | BoxExtent |
TExtent | SphereRadius |
Friends | |
TBoxSphereBounds< T, TExtent > | Union (const TBoxSphereBounds< T, TExtent > &A, const TBoxSphereBounds< T, TExtent > &B) |
Definition at line 23 of file BoxSphereBounds.h.
Definition at line 25 of file BoxSphereBounds.h.
|
inline |
Default constructor.
Definition at line 39 of file BoxSphereBounds.h.
|
inlineexplicit |
Creates and initializes a new instance.
EForceInit | Force Init Enum. |
Definition at line 46 of file BoxSphereBounds.h.
|
inline |
Creates and initializes a new instance from the specified parameters.
InOrigin | origin of the bounding box and sphere. |
InBoxExtent | half size of box. |
InSphereRadius | radius of the sphere. |
Definition at line 61 of file BoxSphereBounds.h.
|
inline |
Creates and initializes a new instance from the given Box and Sphere.
Box | The bounding box. |
Sphere | The bounding sphere. |
Definition at line 75 of file BoxSphereBounds.h.
Creates and initializes a new instance the given Box.
The sphere radius is taken from the extent of the box.
Box | The bounding box. |
Definition at line 93 of file BoxSphereBounds.h.
Creates and initializes a new instance for the given sphere.
Definition at line 107 of file BoxSphereBounds.h.
FORCEINLINE UE::Math::TBoxSphereBounds< T, TExtent >::TBoxSphereBounds | ( | const TVector< T > * | Points, |
uint32 | NumPoints ) |
Creates and initializes a new instance from the given set of points.
The sphere radius is taken from the extent of the box.
Points | The points to be considered for the bounding box. |
NumPoints | Number of points in the Points array. |
Definition at line 353 of file BoxSphereBounds.h.
|
inlineexplicit |
Definition at line 128 of file BoxSphereBounds.h.
|
inlinestatic |
Test whether the boxes from two BoxSphereBounds intersect/overlap.
A | First BoxSphereBounds to test. |
B | Second BoxSphereBounds to test. |
Definition at line 195 of file BoxSphereBounds.h.
|
inline |
Calculates the squared distance from a point to a bounding box
Point | The point. |
Definition at line 167 of file BoxSphereBounds.h.
|
inline |
Definition at line 303 of file BoxSphereBounds.h.
|
inline |
Definition at line 300 of file BoxSphereBounds.h.
|
inline |
Increase the size of the box and sphere by a given size.
ExpandAmount | The size to increase by. |
Definition at line 242 of file BoxSphereBounds.h.
|
inline |
Gets the extrema for the bounding box.
Extrema | 1 for positive extrema from the origin, else negative |
Definition at line 216 of file BoxSphereBounds.h.
|
inline |
Gets the bounding sphere.
Definition at line 231 of file BoxSphereBounds.h.
FORCEINLINE bool UE::Math::TBoxSphereBounds< T, TExtent >::operator!= | ( | const TBoxSphereBounds< T, TExtent > & | Other | ) | const |
Compare bounding volume this and Other.
Other | The other bounding volume. |
Definition at line 406 of file BoxSphereBounds.h.
FORCEINLINE TBoxSphereBounds< T, TExtent > UE::Math::TBoxSphereBounds< T, TExtent >::operator+ | ( | const TBoxSphereBounds< T, TExtent > & | Other | ) | const |
Constructs a bounding volume containing both this and B.
Other | The other bounding volume. |
Definition at line 381 of file BoxSphereBounds.h.
FORCEINLINE bool UE::Math::TBoxSphereBounds< T, TExtent >::operator== | ( | const TBoxSphereBounds< T, TExtent > & | Other | ) | const |
Compare bounding volume this and Other.
Other | The other bounding volume. |
Definition at line 400 of file BoxSphereBounds.h.
FORCEINLINE bool UE::Math::TBoxSphereBounds< T, TExtent >::Serialize | ( | FArchive & | Ar | ) |
Definition at line 412 of file BoxSphereBounds.h.
Definition at line 499 of file BoxSphereBounds.h.
|
inlinestatic |
Test whether the spheres from two BoxSphereBounds intersect/overlap.
A | First BoxSphereBounds to test. |
B | Second BoxSphereBounds to test. |
Tolerance | Error tolerance added to test distance. |
Definition at line 183 of file BoxSphereBounds.h.
FORCEINLINE FString UE::Math::TBoxSphereBounds< T, TExtent >::ToString | ( | ) | const |
Get a textual representation of this bounding box.
Definition at line 419 of file BoxSphereBounds.h.
TBoxSphereBounds< T, TExtent > UE::Math::TBoxSphereBounds< T, TExtent >::TransformBy | ( | const TMatrix< T > & | M | ) | const |
Gets a bounding volume transformed by a matrix.
M | The matrix. |
Definition at line 425 of file BoxSphereBounds.h.
TBoxSphereBounds< T, TExtent > UE::Math::TBoxSphereBounds< T, TExtent >::TransformBy | ( | const TTransform< T > & | M | ) | const |
Gets a bounding volume transformed by a FTransform object.
M | The FTransform object. |
Definition at line 478 of file BoxSphereBounds.h.
|
friend |
Constructs a bounding volume containing both A and B.
This is a legacy version of the function used to compute primitive bounds, to avoid the need to rebuild lighting after the change.
Definition at line 275 of file BoxSphereBounds.h.
TVector<TExtent> UE::Math::TBoxSphereBounds< T, TExtent >::BoxExtent |
Holds the extent of the bounding box.
Definition at line 31 of file BoxSphereBounds.h.
TVector<T> UE::Math::TBoxSphereBounds< T, TExtent >::Origin |
Holds the origin of the bounding box and sphere.
Definition at line 28 of file BoxSphereBounds.h.
TExtent UE::Math::TBoxSphereBounds< T, TExtent >::SphereRadius |
Holds the radius of the bounding sphere.
Definition at line 34 of file BoxSphereBounds.h.