diff --git a/src/Engine/Application.cpp b/src/Engine/Application.cpp index 81a463a759c6f7bc09f5b3360243d4f48898d639..13507ac3afc1a0034070cc91531c3fe2565813e4 100644 --- a/src/Engine/Application.cpp +++ b/src/Engine/Application.cpp @@ -5,6 +5,7 @@ #include "GLFW/glfw3.h" #include <memory> +#include <iostream> namespace Engine { @@ -34,6 +35,11 @@ namespace Engine } } +void error_callback(int error, const char* description) +{ + std::cerr << "GLFW Error: " << description << std::endl;; +} + namespace Engine { namespace Application @@ -51,6 +57,8 @@ namespace Engine data = std::make_unique<Data>(); data->isRunning = true; + glfwSetErrorCallback(error_callback); + glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 4); glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3); glfwWindowHint(GLFW_OPENGL_DEBUG_CONTEXT, GL_TRUE);