Added simple glfw input callbacks

This commit is contained in:
2022-06-10 21:06:45 +02:00
parent 7b9685c381
commit 4df6cfba90
2 changed files with 62 additions and 1 deletions

View File

@ -12,6 +12,13 @@ namespace BarinkEngine {
void PollEvents();
void attach(BarinkWindow* window);
// GLFW Handlers
static void KeyCallback(GLFWwindow* window, int key, int scancode, int action, int mods);
static void CursorPositionCallback(GLFWwindow* window, double x, double y);
static void CursorEnterCallback(GLFWwindow* window, int entered);
static void MouseButtonCallback(GLFWwindow* window, int button, int action, int mods);
static void ScrollCallback(GLFWwindow* window, double xoffset, double yoffset);
private:
std::vector<BarinkWindow*> windows;
};