vengine  0.1.0
3D graphics engine made with Vulkan
Loading...
Searching...
No Matches
KeyboardController.hpp
Go to the documentation of this file.
1///
2/// @file Camera.hpp
3/// @brief This file contains the KeyboardController class
4/// @namespace ven
5///
6
7#pragma once
8
9#include "VEngine/Window.hpp"
10#include "VEngine/Object.hpp"
11
12namespace ven {
13
15
16 public:
17
18 struct KeyMappings {
19 int moveLeft = GLFW_KEY_A;
20 int moveRight = GLFW_KEY_D;
21 int moveForward = GLFW_KEY_W;
22 int moveBackward = GLFW_KEY_S;
23 int moveUp = GLFW_KEY_SPACE;
24 int moveDown = GLFW_KEY_LEFT_SHIFT;
25 int lookLeft = GLFW_KEY_LEFT;
26 int lookRight = GLFW_KEY_RIGHT;
27 int lookUp = GLFW_KEY_UP;
28 int lookDown = GLFW_KEY_DOWN;
29 };
30
31 void moveInPlaneXZ(GLFWwindow* window, float dt, Object& object) const;
32
34 float m_moveSpeed{3.F};
35 float m_lookSpeed{1.5F};
36
37 }; // class KeyboardController
38
39} // namespace ven
This file contains the Object class.
This file contains the Window class.
void moveInPlaneXZ(GLFWwindow *window, float dt, Object &object) const