Skip to content

Commit

Permalink
Fix GLFW error (0x10007): NSGL: The targeted version of macOS only su…
Browse files Browse the repository at this point in the history
…pports forward-compatible core profile contexts for OpenGL 3.2 and above
  • Loading branch information
Stefan committed Oct 17, 2023
1 parent 836e6c4 commit 8890253
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Backends/RmlUi_Backend_GLFW_GL3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,10 @@ bool Backend::Initialize(const char* name, int width, int height, bool allow_res
glfwWindowHint(GLFW_RESIZABLE, allow_resize ? GLFW_TRUE : GLFW_FALSE);
glfwWindowHint(GLFW_SCALE_TO_MONITOR, GLFW_TRUE);

#if __APPLE__
glfwWindowHint(GLFW_OPENGL_FORWARD_COMPAT, GL_TRUE);
#endif

GLFWwindow* window = glfwCreateWindow(width, height, name, nullptr, nullptr);
if (!window)
return false;
Expand Down

0 comments on commit 8890253

Please sign in to comment.