aboutsummaryrefslogtreecommitdiff
path: root/src/window
diff options
context:
space:
mode:
authordec05eba <dec05eba@protonmail.com>2024-08-19 20:39:22 +0200
committerdec05eba <dec05eba@protonmail.com>2024-08-19 20:39:22 +0200
commite419500eafed85d4f7b184ddae75c855bdc45200 (patch)
tree38b77e116fcea14a0bfe17756e209679dcdc0105 /src/window
parent8731a00681a2cf99965203849bd7ba8f6c09df9a (diff)
Add mgl_window_get_egl_context
Diffstat (limited to 'src/window')
-rw-r--r--src/window/window.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/window/window.c b/src/window/window.c
index 1f21e43..6d44dad 100644
--- a/src/window/window.c
+++ b/src/window/window.c
@@ -2117,3 +2117,11 @@ void* mgl_window_get_egl_display(mgl_window *self) {
else
return NULL;
}
+
+void* mgl_window_get_egl_context(mgl_window *self) {
+ x11_context *x11_context = self->context;
+ if(x11_context->render_api == MGL_RENDER_API_EGL)
+ return x11_context->egl.egl_context;
+ else
+ return NULL;
+}