Compiles, not run yet.

This commit is contained in:
Pcornat 2022-01-08 23:40:31 +01:00
parent 9dfe0faa56
commit 01697f9df4
Signed by: Pcornat
GPG key ID: 2F3932FF46D9ECA0
6 changed files with 94 additions and 15 deletions

View file

@ -1,5 +1 @@
//
// Created by postaron on 08/01/2022.
//
#include "gui_data.hpp"

View file

@ -1,8 +1,13 @@
#include <stdexcept>
#include "window.hpp"
#include <stdexcept>
#include <spdlog/spdlog.h>
static void glfwErrorCallback(int error, const char *message) {
spdlog::error("Error code {}: {}", error, message);
}
gui::Window::Window() {
glfwSetErrorCallback(nullptr);
glfwSetErrorCallback(glfwErrorCallback);
if (glfwInit() == GLFW_FALSE) {
throw std::runtime_error("GLFW init failed.");
}