From b0b1442a037be7bc6b07c11920dbf25207a9136e Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sat, 7 Jun 2025 11:47:27 +0200 Subject: Swap flush and memory barrier --- src/egl.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'src/egl.c') diff --git a/src/egl.c b/src/egl.c index 8d37986..6661580 100644 --- a/src/egl.c +++ b/src/egl.c @@ -517,15 +517,7 @@ void gsr_egl_unload(gsr_egl *self) { } void gsr_egl_swap_buffers(gsr_egl *self) { - /* This uses less cpu than swap buffer on nvidia */ - // TODO: Do these and remove swap self->glFlush(); -// self->glFinish(); - // if(self->egl_display) { - // self->eglSwapBuffers(self->egl_display, self->egl_surface); - // } else if(gsr_window_get_display_server(self->window) == GSR_DISPLAY_SERVER_X11) { - // Display *display = gsr_window_get_display(self->window); - // const Window window = (Window)gsr_window_get_window(self->window); - // self->glXSwapBuffers(display, window); - // } + // TODO: Use the minimal barrier required + self->glMemoryBarrier(GL_ALL_BARRIER_BITS); // GL_SHADER_IMAGE_ACCESS_BARRIER_BIT } -- cgit v1.2.3-70-g09d2