![]() |
Murl Engine API
Version 2018.3
|
The IBoundingVolume interface. More...
#include <murl_graph_i_bounding_volume.h>
The IBoundingVolume interface.
This interface represents a simple bounding volume in 3D space that encloses the outer bounds of some geometry, which are used for e.g. visibility determination (a.k.a. culling), and optionally provides an "inner" volume that is used for alignment purposes.
Inherited by Murl::Graph::BoundingVolume.
Public Member Functions | |
virtual Bool | Clear ()=0 |
Clear the bounding volume. More... | |
virtual Bool | SetLocalBounds (const Box &box)=0 |
Set the local bounding volume extent from a box. More... | |
virtual Bool | SetLocalBounds (const Vector &minExtent, const Vector &maxExtent)=0 |
Set the local bounding volume extent. More... | |
virtual Bool | SetLocalBounds (const Box &outerBox, const Box &innerBox)=0 |
Set the local bounding volume extent from an inner and outer box. More... | |
virtual Bool | SetLocalBounds (const Vector &minOuterExtent, const Vector &maxOuterExtent, const Vector &minInnerExtent, const Vector &maxInnerExtent)=0 |
Set the local bounding volume extent. More... | |
virtual Bool | SetLocalBounds (const Sphere &sphere)=0 |
Set the local bounding volume extent from a sphere. More... | |
virtual Bool | SetLocalBounds (const Vector &sphereCenter, Real sphereRadius)=0 |
Set the local bounding volume extent. More... | |
virtual Bool | UniteLocalBounds (const IBoundingVolume *other)=0 |
Unite the local bounding volume with a given other one. More... | |
virtual Bool | UniteLocalBounds (const IBoundingVolume *other, const Matrix &baseTransform, const Vector &baseScale)=0 |
Unite the local bounding volume with a given other one using an additional transformation. More... | |
virtual const Sphere & | GetLocalSphere () const =0 |
Get the bounding sphere in object space. More... | |
virtual const Sphere & | GetWorldSphere () const =0 |
Get the bounding sphere in world space. More... | |
virtual Sphere | CalculateWorldSphereRelativeToBase (const Matrix &baseTransform, const Vector &baseScale) const =0 |
Calculate the bounding sphere relative to a given base transform and scale. More... | |
virtual Sphere | CalculateWorldSphereRelativeToView (const Matrix &viewTransform, const Vector &viewScale) const =0 |
Calculate the bounding sphere relative to a given view transform and scale. More... | |
virtual const Box & | GetOuterLocalBox () const =0 |
Get the outer bounding box in object space. More... | |
virtual const Box & | GetOuterWorldBox () const =0 |
Get the outer bounding box in world space. More... | |
virtual Box | CalculateOuterWorldBoxRelativeToBase (const Matrix &baseTransform, const Vector &baseScale) const =0 |
Calculate the outer bounding box relative to a given base transform and scale. More... | |
virtual Box | CalculateOuterWorldBoxRelativeToView (const Matrix &viewTransform, const Vector &viewScale) const =0 |
Calculate the outer bounding box relative to a given view transform and scale. More... | |
virtual const Box & | GetInnerLocalBox () const =0 |
Get the inner bounding box in object space. More... | |
virtual const Box & | GetInnerWorldBox () const =0 |
Get the inner bounding box in world space. More... | |
virtual Box | CalculateInnerWorldBoxRelativeToBase (const Matrix &baseTransform, const Vector &baseScale) const =0 |
Calculate the inner bounding box relative to a given base transform and scale. More... | |
virtual Box | CalculateInnerWorldBoxRelativeToView (const Matrix &viewTransform, const Vector &viewScale) const =0 |
Calculate the inner bounding box relative to a given view transform and scale. More... | |
virtual Bool | SetWorldTransform (const Matrix &worldTransform)=0 |
Set the bounding volume's current world transform matrix. More... | |
virtual Bool | ClearWorldTransform ()=0 |
Clear the bounding volume's current world transform matrix. More... | |
virtual const Matrix & | GetWorldTransform () const =0 |
Get the bounding volume's current world transform matrix. More... | |
virtual Bool | SetWorldScaleFactor (const Vector &worldScaleFactor)=0 |
Set the bounding volume's current world scale factor. More... | |
virtual Bool | ClearWorldScaleFactor ()=0 |
Reset the bounding volume's current world scale factor to 1. More... | |
virtual const Vector & | GetWorldScaleFactor () const =0 |
Get the bounding volume's current world scale factor. More... | |
virtual Bool | IsIntersecting (const IBoundingVolume *other) const =0 |
Check if the bounding volume intersects another one. More... | |
virtual Bool | IsEmpty () const =0 |
Check if the bounding volume is empty. More... | |
virtual Bool | HasInnerBox () const =0 |
Check if the bounding volume has an inner box. More... | |
|
pure virtual |
Clear the bounding volume.
This method clears the bounding value by setting all of its internal values to zero.
Set the local bounding volume extent from a box.
box | The local bounding box. |
|
pure virtual |
Set the local bounding volume extent.
This method sets the bounding volume to enclose the given minimum and maximum values in local 3D (object) space.
minExtent | A vector containing minimum X, Y and Z values of a bounding box. |
maxExtent | A vector containing maximum X, Y and Z values of a bounding box. |
|
pure virtual |
Set the local bounding volume extent from an inner and outer box.
outerBox | The local outer bounding box. |
innerBox | The local inner bounding box. |
|
pure virtual |
Set the local bounding volume extent.
This method sets the bounding volume to enclose the given minimum and maximum values in local 3D (object) space, for both an inner and outer box.
minOuterExtent | A vector containing minimum values of the outer bounding box. |
maxOuterExtent | A vector containing maximum values of the outer bounding box. |
minInnerExtent | A vector containing minimum values of the inner bounding box. |
maxInnerExtent | A vector containing maximum values of the inner bounding box. |
Set the local bounding volume extent from a sphere.
sphere | The local bounding sphere. |
|
pure virtual |
Set the local bounding volume extent.
This method sets the bounding volume to enclose the sphere represented by the given sphere center and radius.
sphereCenter | The bounding sphere center. |
sphereRadius | The bounding sphere radius. |
|
pure virtual |
Unite the local bounding volume with a given other one.
other | The other bounding volume to unite with. |
|
pure virtual |
Unite the local bounding volume with a given other one using an additional transformation.
other | The other bounding volume to unite with. |
baseTransform | The transform to apply to the other volume. |
baseScale | The scale factor to apply to the other volume. |
|
pure virtual |
Get the bounding sphere in object space.
|
pure virtual |
Get the bounding sphere in world space.
|
pure virtual |
Calculate the bounding sphere relative to a given base transform and scale.
baseTransform | The base transform to use. |
baseScale | The base scale factor to use. |
|
pure virtual |
Calculate the bounding sphere relative to a given view transform and scale.
viewTransform | The view transform to use. |
viewScale | The view scale factor to use. |
|
pure virtual |
Get the outer bounding box in object space.
|
pure virtual |
Get the outer bounding box in world space.
|
pure virtual |
Calculate the outer bounding box relative to a given base transform and scale.
baseTransform | The base transform to use. |
baseScale | The base scale factor to use. |
|
pure virtual |
Calculate the outer bounding box relative to a given view transform and scale.
viewTransform | The view transform to use. |
viewScale | The view scale factor to use. |
|
pure virtual |
Get the inner bounding box in object space.
|
pure virtual |
Get the inner bounding box in world space.
|
pure virtual |
Calculate the inner bounding box relative to a given base transform and scale.
baseTransform | The base transform to use. |
baseScale | The base scale factor to use. |
|
pure virtual |
Calculate the inner bounding box relative to a given view transform and scale.
viewTransform | The view transform to use. |
viewScale | The view scale factor to use. |
|
pure virtual |
Set the bounding volume's current world transform matrix.
worldTransform | The world transform matrix. |
|
pure virtual |
Clear the bounding volume's current world transform matrix.
|
pure virtual |
Get the bounding volume's current world transform matrix.
|
pure virtual |
Set the bounding volume's current world scale factor.
worldScaleFactor | The world scale factor in X, Y and Z direction. |
|
pure virtual |
Reset the bounding volume's current world scale factor to 1.
|
pure virtual |
Get the bounding volume's current world scale factor.
|
pure virtual |
Check if the bounding volume intersects another one.
other | The bounding volume to check against. |
|
pure virtual |
Check if the bounding volume is empty.
|
pure virtual |
Check if the bounding volume has an inner box.