From 40ed05608effeb984a3cfc55f045e69987467283 Mon Sep 17 00:00:00 2001 From: Green Sky Date: Tue, 7 Oct 2025 17:55:37 +0200 Subject: [PATCH] print sdl version at startup --- src/main.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/main.cpp b/src/main.cpp index 154fd4e..c2f7610 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -68,6 +68,19 @@ int main(int argc, char** argv) { auto last_time_render = std::chrono::steady_clock::now(); auto last_time_tick = std::chrono::steady_clock::now(); + std::cout + << "SDL version: " + << SDL_VERSIONNUM_MAJOR(SDL_VERSION) << "." + << SDL_VERSIONNUM_MINOR(SDL_VERSION) << "." + << SDL_VERSIONNUM_MICRO(SDL_VERSION) + << " (compiled)\n"; + std::cout << "SDL version: " + << SDL_VERSIONNUM_MAJOR(SDL_GetVersion()) << "." + << SDL_VERSIONNUM_MINOR(SDL_GetVersion()) << "." + << SDL_VERSIONNUM_MICRO(SDL_GetVersion()) + << "-" << SDL_GetRevision() + << " (linked)\n"; + // actual setup if (!SDL_Init(SDL_INIT_VIDEO)) { std::cerr << "SDL_Init failed (" << SDL_GetError() << ")\n";