Epok Engine

EPOK RUNTIME

epok::camera2d_pixels_per_unit

Function · 1 overload

Function

Performs `camera2d pixels per unit` as part of the world2d module.

Belongs to
epok
Header
world2d.hpp
Overloads
1

Declaration

Declaration
inline Fixed camera2d_pixels_per_unit(const Camera2D& camera)

Performs `camera2d pixels per unit` as part of the world2d module.

ParameterTypeMeaning
cameraconst Camera2D &Value supplied for camera. Keep referenced or pointed-to data valid for the complete call.

Returns: Fixed. Check the value before continuing when it represents success, availability or a resource handle.

Example

C++ example
#include "world2d.hpp"

// Assume these named values have been initialized with valid data:
// const Camera2D & camera

auto result = epok::camera2d_pixels_per_unit(camera);

Why use it

It provides direct, allocation-conscious access to the world2d module. No exception-based error path is implied by the signature.

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/world2d.hpp:221

Related members