MCPcopy Create free account
hub / github.com/crownengine/crown / camera_view_matrix

Method camera_view_matrix

src/world/world.cpp:679–688  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

677}
678
679Matrix4x4 World::camera_view_matrix(CameraId camera)
680{
681 TransformId ti = _scene_graph->instance(_camera[camera.i].unit);
682 Matrix4x4 view = _scene_graph->world_pose(ti);
683 Matrix4x4 rotate_x_90 = from_matrix3x3(from_x_axis_angle(frad(90.0f)));
684
685 view = rotate_x_90 * view;
686 invert(view);
687 return view;
688}
689
690f32 World::camera_fov(CameraId camera)
691{

Callers 1

renderMethod · 0.80

Calls 4

from_matrix3x3Function · 0.85
from_x_axis_angleFunction · 0.85
world_poseMethod · 0.80
instanceMethod · 0.45

Tested by

no test coverage detected