OS X EGL context api support with ANGLE

This commit is contained in:
Konya Tamas 2019-10-03 13:24:47 +02:00
parent 243b1bc292
commit 788a1e4a43
2 changed files with 3 additions and 1 deletions

View File

@ -81,7 +81,7 @@ typedef VkResult (APIENTRY *PFN_vkCreateMacOSSurfaceMVK)(VkInstance,const VkMacO
#define _glfw_dlclose(handle) dlclose(handle)
#define _glfw_dlsym(handle, name) dlsym(handle, name)
#define _GLFW_EGL_NATIVE_WINDOW ((EGLNativeWindowType) window->ns.view)
#define _GLFW_EGL_NATIVE_WINDOW ((EGLNativeWindowType) window->ns.layer)
#define _GLFW_EGL_NATIVE_DISPLAY EGL_DEFAULT_DISPLAY
#define _GLFW_PLATFORM_WINDOW_STATE _GLFWwindowNS ns

View File

@ -849,6 +849,8 @@ static GLFWbool createNativeWindow(_GLFWwindow* window,
[window->ns.object setBackgroundColor:[NSColor clearColor]];
}
[window->ns.view setWantsLayer:YES];
window->ns.layer = [window->ns.view layer];
[window->ns.object setContentView:window->ns.view];
[window->ns.object makeFirstResponder:window->ns.view];
[window->ns.object setTitle:@(wndconfig->title)];