Epok Engine

EPOK RUNTIME

epok::CollisionWorld::raycast_batch

Method · 1 overload

Method

Performs `raycast batch` as part of bounded AABB collision queries and movement.

Belongs to
epok::CollisionWorld
Header
collision.hpp
Overloads
1

Declaration

const
Declaration
void raycast_batch(const RaycastQueryT<Number>* queries,SpatialHitT<Number>* results,size_t count, uint32_t mask=0xffffffffu,int ignore=-1,bool triggers=false) const

Performs `raycast batch` as part of bounded AABB collision queries and movement.

ParameterTypeMeaning
queriesconst RaycastQueryT<Number> *Value supplied for queries. Keep referenced or pointed-to data valid for the complete call.
resultsSpatialHitT<Number> *Value supplied for results. Keep referenced or pointed-to data valid for the complete call.
countsize_tValue supplied for count. Keep referenced or pointed-to data valid for the complete call.
maskuint32_tValue supplied for mask. Keep referenced or pointed-to data valid for the complete call.
ignoreintValue supplied for ignore. Keep referenced or pointed-to data valid for the complete call.
triggersboolValue supplied for triggers. Keep referenced or pointed-to data valid for the complete call.

Returns: Nothing (void).

Example

C++ example
#include "collision.hpp"

// Assume these named values have been initialized with valid data:
// const RaycastQueryT<Number> * queries
// SpatialHitT<Number> * results
// size_t count
// uint32_t mask
// int ignore
// bool triggers

epok::CollisionWorld& object = /* obtain a valid instance */;

object.raycast_batch(queries, results, count, mask, ignore, triggers);

Why use it

The method is `const`, so it does not mutate the object through this API surface.

Trade-offs and warnings

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:223

Related members