Epok Engine

EPOK RUNTIME

epok::project_cpu

Function template · 1 overload

Function template

CPU perspective for clipped or fallback vertices, rounding like the GTE so mixed triangles share edges.

Belongs to
epok
Header
polygon.hpp
Overloads
1

Declaration

template
Declaration
template<class Units, int Width, int Height> inline void project_cpu(ProjectedVertex& point)

CPU perspective for clipped or fallback vertices, rounding like the GTE so mixed triangles share edges.

ParameterTypeMeaning
pointProjectedVertex &Value supplied for point. Keep referenced or pointed-to data valid for the complete call.

Returns: Nothing (void).

Example

C++ example
#include "polygon.hpp"

// Replace these template arguments with types or values accepted by the declaration:
// Units, Width, Height

// Assume these named values have been initialized with valid data:
// ProjectedVertex & point

epok::project_cpu<Units, Width, Height>(point);

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/polygon.hpp:77

Related members