Browse Source

Fix: unable to create gl context on desktop with ANGLE + GLFW3

pull/481/head
Tracy Ma 6 years ago committed by Vladimír Vondruš
parent
commit
6a345ea982
  1. 6
      src/Magnum/Platform/GlfwApplication.cpp

6
src/Magnum/Platform/GlfwApplication.cpp

@ -451,6 +451,9 @@ bool GlfwApplication::tryCreate(const Configuration& configuration, const GLConf
}
#else
glfwWindowHint(GLFW_CLIENT_API, GLFW_OPENGL_ES_API);
#if defined(CORRADE_TARGET_WINDOWS) && !defined(MAGNUM_TARGET_DESKTOP_GLES)
glfwWindowHint(GLFW_CONTEXT_CREATION_API, GLFW_EGL_CONTEXT_API);
#endif
#endif
/* Request usable version otherwise */
@ -475,6 +478,9 @@ bool GlfwApplication::tryCreate(const Configuration& configuration, const GLConf
#endif
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 0);
glfwWindowHint(GLFW_CLIENT_API, GLFW_OPENGL_ES_API);
#if defined(CORRADE_TARGET_WINDOWS) && !defined(MAGNUM_TARGET_DESKTOP_GLES)
glfwWindowHint(GLFW_CONTEXT_CREATION_API, GLFW_EGL_CONTEXT_API);
#endif
#endif
}

Loading…
Cancel
Save