Enum in ldk_camera.h

LDKCameraProjection

typedef enum LDKCameraProjection{
  LDK_CAMERA_PROJECTION_PERSPECTIVE=0,
  LDK_CAMERA_PROJECTION_ORTHOGRAPHIC
}LDKCameraProjection;
Enum in ldk_camera.h

LDKCameraRole

typedef enum LDKCameraRole{
  LDK_CAMERA_ROLE_NONE=0,
  LDK_CAMERA_ROLE_MAIN,
  LDK_CAMERA_ROLE_EDITOR,
  LDK_CAMERA_ROLE_RENDER_TARGET
}LDKCameraRole;
Enum in ldk_camera.h

LDKCameraBackgroundMode

typedef enum LDKCameraBackgroundMode{
  LDK_CAMERA_BACKGROUND_COLOR=0,
  LDK_CAMERA_BACKGROUND_SKYBOX,
  LDK_CAMERA_BACKGROUND_NONE
}LDKCameraBackgroundMode;
Function in ldk_camera.h

ldk_camera_component_desc

Build the ECS registration descriptor for the camera component.

LDK_API LDKComponentDesc ldk_camera_component_desc(u32 initial_capacity);

Parameters

u32 initial_capacity
Initial number of entries reserved in the registry.

Returns

A descriptor for the requested component or resource.

Function in ldk_camera.h

ldk_camera_look_at

Orient a camera entity so it looks toward a world-space target.

LDK_API bool ldk_camera_look_at(
 LDKEntity entity,
 Vec3 target
);

Parameters

LDKEntity entity
Entity to inspect or modify.
Vec3 target
Target used by this operation.

Returns

True if the operation succeeds; false otherwise.

Function in ldk_camera.h

ldk_camera_get_world_matrix

Get camera world matrix.

LDK_API bool ldk_camera_get_world_matrix(
 LDKEntity entity,
 Mat4 *out_world
);

Parameters

LDKEntity entity
Entity to inspect or modify.
Mat4 *out_world
Receives the computed world transformation matrix.

Returns

True if the operation succeeds; false otherwise.

Function in ldk_camera.h

ldk_camera_get_view_matrix

Get camera view matrix.

LDK_API bool ldk_camera_get_view_matrix(
 LDKEntity entity,
 Mat4 *out_view
);

Parameters

LDKEntity entity
Entity to inspect or modify.
Mat4 *out_view
Receives the camera view matrix.

Returns

True if the operation succeeds; false otherwise.

Function in ldk_camera.h

ldk_camera_get_projection_matrix

Get camera projection matrix.

LDK_API bool ldk_camera_get_projection_matrix(
 LDKEntity entity,
 float aspect,
 Mat4 *out_projection
);

Parameters

LDKEntity entity
Entity to inspect or modify.
float aspect
Viewport aspect ratio.
Mat4 *out_projection
Receives the projection matrix.

Returns

True if the operation succeeds; false otherwise.