summaryrefslogtreecommitdiff
path: root/Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c
diff options
context:
space:
mode:
Diffstat (limited to 'Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c')
-rw-r--r--Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c b/Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c
index 7a0b079..fc6304d 100644
--- a/Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c
+++ b/Source/3rdParty/SDL2/src/video/kmsdrm/SDL_kmsdrmopengles.c
@@ -50,23 +50,23 @@ KMSDRM_GLES_SetupCrtc(_THIS, SDL_Window * window) {
KMSDRM_FBInfo *fb_info;
if (!(_this->egl_data->eglSwapBuffers(_this->egl_data->egl_display, wdata->egl_surface))) {
- SDL_LogError(SDL_LOG_CATEGORY_VIDEO, "eglSwapBuffers failed on CRTC setup");
- return SDL_FALSE;
+ SDL_LogError(SDL_LOG_CATEGORY_VIDEO, "eglSwapBuffers failed on CRTC setup");
+ return SDL_FALSE;
}
- wdata->next_bo = KMSDRM_gbm_surface_lock_front_buffer(wdata->gs);
- if (wdata->next_bo == NULL) {
- SDL_LogError(SDL_LOG_CATEGORY_VIDEO, "Could not lock GBM surface front buffer on CRTC setup");
- return SDL_FALSE;
+ wdata->crtc_bo = KMSDRM_gbm_surface_lock_front_buffer(wdata->gs);
+ if (wdata->crtc_bo == NULL) {
+ SDL_LogError(SDL_LOG_CATEGORY_VIDEO, "Could not lock GBM surface front buffer on CRTC setup");
+ return SDL_FALSE;
}
- fb_info = KMSDRM_FBFromBO(_this, wdata->next_bo);
+ fb_info = KMSDRM_FBFromBO(_this, wdata->crtc_bo);
if (fb_info == NULL) {
- return SDL_FALSE;
+ return SDL_FALSE;
}
if(KMSDRM_drmModeSetCrtc(vdata->drm_fd, displaydata->crtc_id, fb_info->fb_id,
- 0, 0, &vdata->saved_conn_id, 1, &displaydata->cur_mode) != 0) {
+ 0, 0, &vdata->saved_conn_id, 1, &displaydata->cur_mode) != 0) {
SDL_LogWarn(SDL_LOG_CATEGORY_VIDEO, "Could not set up CRTC to a GBM buffer");
return SDL_FALSE;
@@ -153,14 +153,14 @@ KMSDRM_GLES_SwapWindow(_THIS, SDL_Window * window) {
} else {
/* Queue page flip at vsync */
- /* Have we already setup the CRTC to one of the GBM buffers? Do so if we have not,
+ /* Have we already setup the CRTC to one of the GBM buffers? Do so if we have not,
or FlipPage won't work in some cases. */
- if (!wdata->crtc_ready) {
+ if (!wdata->crtc_ready) {
if(!KMSDRM_GLES_SetupCrtc(_this, window)) {
SDL_LogError(SDL_LOG_CATEGORY_VIDEO, "Could not set up CRTC for doing vsync-ed pageflips");
return 0;
}
- }
+ }
/* SDL_LogDebug(SDL_LOG_CATEGORY_VIDEO, "drmModePageFlip(%d, %u, %u, DRM_MODE_PAGE_FLIP_EVENT, &wdata->waiting_for_flip)",
vdata->drm_fd, displaydata->crtc_id, fb_info->fb_id); */