MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Samples / get_view

Method get_view

framework/scene_graph/components/camera.cpp:36–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

34}
35
36glm::mat4 Camera::get_view() const
37{
38 if (!node)
39 {
40 throw std::runtime_error{"Camera component is not attached to a node"};
41 }
42
43 auto &transform = node->get_component<Transform>();
44 return glm::inverse(transform.get_world_matrix());
45}
46
47void Camera::set_node(vkb::scene_graph::NodeC &n)
48{

Callers 5

update_uniform_implMethod · 0.80
drawMethod · 0.80
drawMethod · 0.80
fill_mvpFunction · 0.80
drawMethod · 0.80

Calls 1

get_world_matrixMethod · 0.80

Tested by

no test coverage detected