use x11 as windowing platform with glfw for now

This commit is contained in:
IlyaShurupov 2024-06-18 13:40:35 +03:00
parent e45cf0ff46
commit 787681d320

View file

@ -63,6 +63,8 @@ Window* Window::createWindow(Vec2F size, const char* title) {
} }
count--; count--;
glfwInitHint(GLFW_PLATFORM, GLFW_PLATFORM_X11);
// Initialize GLFW // Initialize GLFW
if (!glfwInit()) { if (!glfwInit()) {
printf("Failed to initialize GLFW\n"); printf("Failed to initialize GLFW\n");
@ -70,7 +72,9 @@ Window* Window::createWindow(Vec2F size, const char* title) {
} }
// Set the GLFW error callback // Set the GLFW error callback
glfwSetErrorCallback([](int error, const char* description) { printf("GLFW Error: %i %s\n", error, description); }); glfwSetErrorCallback([](int error, const char* description) {
printf("GLFW Error: %i %s\n", error, description);
});
auto out = new Window(size, title); auto out = new Window(size, title);