From 762a819711f08d2ffbe90c5e4853f77921814ca2 Mon Sep 17 00:00:00 2001 From: Sergio Valor Date: Tue, 10 Sep 2024 12:56:25 +0200 Subject: [PATCH] =?UTF-8?q?A=C3=B1adido=20SDL=5FGetError=20a=20SDL=5FSetWi?= =?UTF-8?q?ndowDisplayMode?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/common/screen.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/source/common/screen.cpp b/source/common/screen.cpp index ea31276..3d41698 100644 --- a/source/common/screen.cpp +++ b/source/common/screen.cpp @@ -178,7 +178,14 @@ void Screen::setVideoMode(int videoMode) DM.w = 1024; DM.h = 600; DM.refresh_rate = 60; - SDL_SetWindowDisplayMode(window, &DM); + if (!SDL_SetWindowDisplayMode(window, &DM)) + { + stc::cout << SDL_GetError() << std::endl; + } + else + { + stc::cout << "Changed windows display mode" << std::endl; + } #endif // Oculta el puntero