This page has been translated automatically.
UnigineScript
The Language
Core Library
Engine Library
Node-Related Classes
GUI-Related Classes
Plugins Library
High-Level Systems
Samples
Usage Examples
C++ API
API Reference
Integration Samples
Usage Examples
C++ Plugins
Migration
Migrating to UNIGINE 2.0
C++ API Migration
Migrating from UNIGINE 2.0 to UNIGINE 2.1
Внимание! Эта версия документация УСТАРЕЛА, поскольку относится к более ранней версии SDK! Пожалуйста, переключитесь на самую актуальную документацию для последней версии SDK.
Внимание! Эта версия документации описывает устаревшую версию SDK, которая больше не поддерживается! Пожалуйста, обновитесь до последней версии SDK.

Unigine::BoundFrustum Class

Bounding frustum.

To use this class, include the UnigineBounds.h file.

Unigine::BoundFrustum Class

Members


BoundFrustum ()

Default constructor that produces an empty bounding frustum.

BoundFrustum (const mat4 & projection, const mat4 & modelview)

Initialization by matrices.

Arguments

  • const mat4 & projection - A projection matrix.
  • const mat4 & modelview - A modelview matrix.

BoundFrustum (const BoundFrustum & bf)

Initialization by the bounding frustum.

Arguments

  • const BoundFrustum & bf - The bounding frustum.

BoundFrustum (const BoundFrustum & bf, const mat4 & itransform)

Initialization by the bounding frustum and transformation matrix.

Arguments

  • const BoundFrustum & bf - The bounding frustum.
  • const mat4 & itransform - The inverse transformation matrix.

~BoundFrustum ()

Destructor.

void clear ()

Clears the bounding frustum.

void set (const mat4 & projection, const mat4 & modelview)

Sets the bounding frustum by matrices.

Arguments

  • const mat4 & projection - A projection matrix.
  • const mat4 & modelview - A modelview matrix.

void set (const BoundFrustum & bf)

Sets the bounding frustum by the bounding frustum.

Arguments

  • const BoundFrustum & bf - The bounding frustum.

void set (const BoundFrustum & bf, const mat4 & itransform)

Sets the bounding frustum by the bounding frustum and transformation matrix.

Arguments

  • const BoundFrustum & bf - The bounding frustum.
  • const mat4 & itransform - The inverse transformation matrix.

int inside (const vec3 & point, float radius) const

Checks if the sphere is inside the bounding frustum.

Arguments

  • const vec3 & point - The coordinates of the center of the sphere.
  • float radius - The sphere radius.

Return value

Return 1 if the sphere is inside the bounding frustum; otherwise, 0 is returned.

int inside (const vec3 & min, const vec3 & max) const

Checks if the box is inside the bounding frustum.

Arguments

  • const vec3 & min - The box minimum coordinate.
  • const vec3 & max - The box maximum coordinate.

Return value

Return 1 if the box is inside the bounding frustum; otherwise, 0 is returned.

int inside (const BoundSphere & bs) const

Checks if the bounding sphere is inside the bounding frustum.

Arguments

  • const BoundSphere & bs - The bounding sphere.

Return value

Return 1 if the bounding sphere is inside the bounding frustum; otherwise, 0 is returned.

int inside (const BoundBox & bb) const

Checks if the bounding box is inside the bounding frustum.

Arguments

  • const BoundBox & bb - The bounding box.

Return value

Return 1 if the bounding box is inside the bounding frustum; otherwise, 0 is returned.

UNIGINE_INLINE int isValid () const

Checks the bounding frustum status.

Return value

Return 1 if the bounding frustum is valid.

UNIGINE_INLINE const mat4 & getProjection () const

Gets the bounding frustum projection matrix.

Return value

The bounding frustum projection matrix.

UNIGINE_INLINE const mat4 & getModelview () const

Gets the bounding frustum modelview matrix.

Return value

The bounding frustum modelview matrix.

UNIGINE_INLINE const vec4 * getPlanes () const

Gets the bounding frustum cliping planes array.

Return value

The bounding frustum cliping planes array.
Last update: 03.07.2017
Build: ()