From 31e419a134b7a026552c09d10ee239d3d1635682 Mon Sep 17 00:00:00 2001 From: IoIxD Date: Fri, 5 Dec 2025 18:53:49 -0700 Subject: [PATCH] context doesn't need to be recreated on resize --- src/backend/wayland.c | 25 ------------------------- 1 file changed, 25 deletions(-) diff --git a/src/backend/wayland.c b/src/backend/wayland.c index 15f9724..b588f04 100644 --- a/src/backend/wayland.c +++ b/src/backend/wayland.c @@ -251,31 +251,6 @@ static MwBool egl_setup(MwLL self, int width, int height) { static void egl_resetup(MwLL handle) { int err; - if(!handle->wayland.egl_do_resetup) { - return; - } - - if(!eglMakeCurrent(handle->wayland.egl_display, 0, 0, handle->wayland.egl_context)) { - printf("ERROR: eglMakeCurrent, %0X\n", eglGetError()); - return; - } - - if(!eglDestroySurface(handle->wayland.egl_display, handle->wayland.egl_surface)) { - printf("ERROR: eglDestroySurface, %0X\n", eglGetError()); - return; - }; - - handle->wayland.egl_surface = eglCreateWindowSurface(handle->wayland.egl_display, handle->wayland.egl_config, handle->wayland.egl_window_native, NULL); - if(handle->wayland.egl_surface == EGL_NO_SURFACE) { - printf("ERROR: eglCreateWindowSurface, %0X\n", eglGetError()); - return; - } - - if(!eglMakeCurrent(handle->wayland.egl_display, handle->wayland.egl_surface, handle->wayland.egl_surface, handle->wayland.egl_context)) { - printf("ERROR: eglMakeCurrent, %0X\n", eglGetError()); - return; - } - glDeleteTextures(1, &handle->wayland.fbo_texture); glGenTextures(1, &handle->wayland.fbo_texture); glBindTexture(GL_TEXTURE_2D, handle->wayland.fbo_texture);