bugfix: set core profile to 3.3
@@ -135,11 +135,18 @@ private void initGLFW() {
private void initWindow() {
logger.info("Initializing display (if last line in log then likely the game crashed from an issue with your " +
"video card)");
+
+ // set opengl core profile to 3.3
+ GLFW.glfwWindowHint(GLFW.GLFW_CONTEXT_VERSION_MAJOR, 3);
+ GLFW.glfwWindowHint(GLFW.GLFW_CONTEXT_VERSION_MINOR, 3);
+ GLFW.glfwWindowHint(GLFW.GLFW_OPENGL_PROFILE, GLFW.GLFW_OPENGL_CORE_PROFILE);
+
long window = GLFW.glfwCreateWindow(
config.getWindowWidth(), config.getWindowHeight(), "Terasology Alpha", 0, 0);
if (window == 0) {
throw new RuntimeException("Failed to create window");
}
+
GLFW.glfwMakeContextCurrent(window);
if (!config.isVSync()) {
