Log SDL2 window size at window creation
This commit is contained in:
parent
506a6c303e
commit
0ecc33cc29
1 changed files with 3 additions and 0 deletions
|
|
@ -72,6 +72,9 @@ namespace psemek::sdl2
|
||||||
if (!window_)
|
if (!window_)
|
||||||
sdl2::fail("Failed to create window: ");
|
sdl2::fail("Failed to create window: ");
|
||||||
|
|
||||||
|
SDL_GetWindowSize(window_, &display_mode.w, &display_mode.h);
|
||||||
|
log::info() << "Created SDL2 window " << display_mode.w << 'x' << display_mode.h;
|
||||||
|
|
||||||
#if defined(PSEMEK_GRAPHICS_API_OPENGL)
|
#if defined(PSEMEK_GRAPHICS_API_OPENGL)
|
||||||
gl_context_ = SDL_GL_CreateContext(window_);
|
gl_context_ = SDL_GL_CreateContext(window_);
|
||||||
if (!gl_context_)
|
if (!gl_context_)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue