SDL_HINT_LOGGING(3)
π NAME π
SDL_HINT_LOGGING β bestie, it's the variable that controls the default SDL log levels. the vibes of your logs? she decides them. periodt.
β¨ SYNOPSIS β¨
#include <SDL3/SDL_hints.h>
#define SDL_HINT_LOGGING "SDL_LOGGING"
π DESCRIPTION π
okay so this variable is literally a comma separated set of category=level tokens, and those tokens define the default logging levels for SDL applications. like, the whole personality of your logs, set in one string. iconic behavior honestly.
The category can be a numeric category, or one of these little guys: "app", "error", "assert", "system", "audio", "video", "render", "input", "test", or * for any unspecified category. yes, the star is the "everyone else" of categories, she's the main character for real.
The level can be a numeric level, or one of: "verbose", "debug", "info", "warn", "error", "critical", or "quiet" to disable that category. and yes "quiet" is the "no thoughts, head empty" option, she mutes the whole category π
You can omit the category entirely if you just want to set the logging level for all categories. lowkey the laziest slay and we respect it.
If this hint isn't set, the default log levels are equivalent to:
app=info,assert=warn,test=verbose,*=error
If the DEBUG_INVOCATION environment variable is set to "1", the default log levels are equivalent to:
assert=warn,test=verbose,*=debug
This hint can be set anytime. no waiting around, no prerequisites, she's flexible like that π¦
fr fr, copy those two default lines exactly as-is β the comma placement and the * are doing the heavy lifting and you do not want to mess with them.
πΈ AVAILABILITY πΈ
This hint is available since SDL 3.2.0. so if you're on anything older, bestie, I'm so sorry, this one's not for you yet π
and that's the whole page, no cap. this was Simple Directmedia Layer's man page for SDL_HINT_LOGGING(3), sitting in the SDL3 FUNCTIONS section, shipping with version SDL 3.4.18 and dated the same. ty for coming to my ted talk, go set your log levels, you're gonna eat π«Άβ¨
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms