From 9cb7a7592b47bacc937c580b0575530bceedd12d Mon Sep 17 00:00:00 2001 From: LinlyBoi Date: Thu, 1 Aug 2024 12:31:06 +0300 Subject: [PATCH] buffer callback + input --- pog.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pog.cpp b/pog.cpp index ed20733..a92be6e 100644 --- a/pog.cpp +++ b/pog.cpp @@ -114,3 +114,10 @@ int main() { glfwTerminate(); return 0; } +void framebuffer_size_callback(GLFWwindow *window, int width, int height) { + glViewport(0, 0, width, height); +} +void processInput(GLFWwindow *window) { + if (glfwGetKey(window, GLFW_KEY_ESCAPE) == GLFW_PRESS) + glfwSetWindowShouldClose(window, true); +}