Explorar el Código

The default swap interval on EGL is 1, according to the spec

Fixes https://github.com/libsdl-org/SDL/issues/14014

(cherry picked from commit 137b0b2bee2bb9dd76e2c260970ccf7ff0621692)
Sam Lantinga hace 5 meses
padre
commit
97a8bb44e6
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      src/video/SDL_egl.c

+ 2 - 1
src/video/SDL_egl.c

@@ -1078,7 +1078,8 @@ SDL_GLContext SDL_EGL_CreateContext(SDL_VideoDevice *_this, EGLSurface egl_surfa
         return NULL;
         return NULL;
     }
     }
 
 
-    _this->egl_data->egl_swapinterval = 0;
+    // The default swap interval is 1, according to the spec
+    _this->egl_data->egl_swapinterval = 1;
 
 
     if (!SDL_EGL_MakeCurrent(_this, egl_surface, (SDL_GLContext)egl_context)) {
     if (!SDL_EGL_MakeCurrent(_this, egl_surface, (SDL_GLContext)egl_context)) {
         // Delete the context
         // Delete the context