FBoxSphereBounds

Structure for a combined axis aligned bounding box and bounding sphere with the same origin.

Windows
MacOS
Linux

Syntax

struct FBoxSphereBounds

Remarks

Structure for a combined axis aligned bounding box and bounding sphere with the same origin. (28 bytes).

Variables

Name Description

Public variable

FVector

 

BoxExtent

Holds the extent of the bounding box.

Public variable

FVector

 

Origin

Holds the origin of the bounding box and sphere.

Public variable

float

 

SphereRadius

Holds the radius of the bounding sphere.

Constructors

Name Description

Public function

FBoxSphereBounds()

Default constructor.

Public function

FBoxSphereBounds

(
    EForceInit
)

Creates and initializes a new instance.

Public function

FBoxSphereBounds

(
    const FBox& Box
)

Creates and initializes a new instance the given Box.

Public function

FBoxSphereBounds

(
    const FSphere& Sphere
)

Creates and initializes a new instance for the given sphere.

Public function

FBoxSphereBounds

(
    const FBox& Box,
    const FSphere& Sphere
)

Creates and initializes a new instance from the given Box and Sphere.

Public function

FBoxSphereBounds

(
    const FVector* Points,
    uint32 NumPoints
)

Creates and initializes a new instance from the given set of points.

Public function

FBoxSphereBounds

(
    const FVector& InOrigin,
    const FVector& InBoxExtent,
    float InSphereRadius
)

Creates and initializes a new instance from the specified parameters.

Functions

Name Description

Public function Static

bool

 

BoxesIntersect

(
    const FBoxSphereBounds& A,
    const FBoxSphereBounds& B
)

Test whether the boxes from two BoxSphereBounds intersect/overlap.

Public function Const

float

 

ComputeSquaredDistanceFromBoxToPoint

(
    const FVector& Point
)

Calculates the squared distance from a point to a bounding box

Public function Const

bool

 

ContainsNaN()

Public function Const

void

 

DiagnosticCheckNaN()

Public function Const

FBoxSphereBo...

 

ExpandBy

(
    float ExpandAmount
)

Increase the size of the box and sphere by a given size.

Public function Const

FBox

 

GetBox()

Gets the bounding box.

Public function Const

FVector

 

GetBoxExtrema

(
    uint32 Extrema
)

Gets the extrema for the bounding box.

Public function Const

FSphere

 

GetSphere()

Gets the bounding sphere.

Public function Static

bool

 

SpheresIntersect

(
    const FBoxSphereBounds& A,
    const FBoxSphereBounds& B,
    float Tolerance
)

Test whether the spheres from two BoxSphereBounds intersect/overlap.

Public function Const

FString

 

ToString()

Get a textual representation of this bounding box.

Public function Const

FBoxSphereBo...

 

TransformBy

(
    const FMatrix& M
)

Gets a bounding volume transformed by a matrix.

Public function Const

FBoxSphereBo...

 

TransformBy

(
    const FTransform& M
)

Gets a bounding volume transformed by a FTransform object.

Operators

Name Description

Public function Const

bool

 

operator!=

(
    const FBoxSphereBounds& Other
)

Compare bounding volume this and Other.

Public function Const

FBoxSphereBo...

 

operator+

(
    const FBoxSphereBounds& Other
)

Constructs a bounding volume containing both this and B.

Public function Const

bool

 

operator==

(
    const FBoxSphereBounds& Other
)

Compare bounding volume this and Other.

References

Module

Core

Header

Runtime/Core/Public/Math/BoxSphereBounds.h

Welcome to the new Unreal Engine 4 Documentation site!

We're working on lots of new features including a feedback system so you can tell us how we are doing. It's not quite ready for use in the wild yet, so head over to the Documentation Feedback forum to tell us about this page or call out any issues you are encountering in the meantime.

We'll be sure to let you know when the new system is up and running.

Post Feedback