.antialiasing = 4,
.mipmap = true,
.render_distance = 255.0,
+ .vsync = true,
};
__attribute__((constructor)) static void client_config_init()
.type = CT_FLOAT,
.key = "render_distance",
.value = &client_config.render_distance,
+ },
+ {
+ .type = CT_BOOL,
+ .key = "vsync",
+ .value = &client_config.vsync,
}
- }, 3);
+ }, 4);
}
glfwMakeContextCurrent(window.handle);
+ if (! client_config.vsync)
+ glfwSwapInterval(0);
+
if (glewInit() != GLEW_OK) {
fprintf(stderr, "Failed to initialize GLEW\n");
return false;