Epok Engine

EPOK RUNTIME

epok::collider_bounds

Function template · 1 overload

Function template

Performs `collider bounds` as part of bounded AABB collision queries and movement.

Belongs to
epok
Header
collision.hpp
Overloads
1

Declaration

template
Declaration
template<class Number> inline AabbT<Number> collider_bounds(const ColliderT<Number>& c,const Affine<Number>& world)

Performs `collider bounds` as part of bounded AABB collision queries and movement.

ParameterTypeMeaning
cconst ColliderT<Number> &Value supplied for c. Keep referenced or pointed-to data valid for the complete call.
worldconst Affine<Number> &Value supplied for world. Keep referenced or pointed-to data valid for the complete call.

Returns: AabbT<Number>. Check the value before continuing when it represents success, availability or a resource handle.

Example

C++ example
#include "collision.hpp"

// Replace these template arguments with types or values accepted by the declaration:
// Number

// Assume these named values have been initialized with valid data:
// const ColliderT<Number> & c
// const Affine<Number> & world

auto result = epok::collider_bounds<Number>(c, world);

Why use it

Template dispatch is resolved at compile time and normally adds no runtime indirection.

Trade-offs and warnings

Every instantiated type must satisfy the header's compile-time requirements; extra instantiations can increase code size. Pointer/reference arguments are borrowed unless the source contract says otherwise; keep them valid for the complete operation and never assume null is accepted.

Declared in runtime/collision.hpp:51

Related members