SDL_HINT_FRA..._ACCELERATION(3)
π NAME π
SDL_HINT_FRAMEBUFFER_ACCELERATION β bestie, this is a variable that controls how 3D acceleration gets used to speed up the SDL screen surface. yes literally. she's the girl behind the curtain making your screen surface go zoom. β¨
(also hi, you're reading a page from the SDL3 FUNCTIONS manual, welcome to the function section, we have snacks π)
π SYNOPSIS π
#include <SDL3/SDL_hints.h>
#define SDL_HINT_FRAMEBUFFER_ACCELERATION "SDL_FRAMEBUFFER_ACCELERATION"
that's it. that's the whole vibe. copy it exactly, no cap. π«Ά
β¨ DESCRIPTION β¨
okay so. SDL can try to accelerate the SDL screen surface by using streaming textures with a 3D rendering engine. it's giving main character energy for your framebuffer. and this variable? this variable is the one holding the aux cord deciding whether that happens and how. π
you can set the variable to these values, and I need you to know all three, not just the first one:
"0"β disable 3D acceleration. she's staying home tonight. π"1"β enable 3D acceleration, using the default renderer. this is the default, so if you do nothing, this is the energy you get. π"X"β enable 3D acceleration, usingXwhereXis one of the valid rendering drivers. (e.g."direct3d","opengl", etc.) pick your fighter. π
β οΈ important, bestie: this hint should be set before calling SDL_GetWindowSurface(). before. not after. not during. before. she does not do late arrivals. π
π¦ AVAILABILITY π¦
this hint is available since SDL 3.2.0. if you're on something older, sorry queen, no acceleration lore for you. π
that's the whole page!! go forth and set your hints before you call SDL_GetWindowSurface(), mwah π
β written up for the Simple Directmedia Layer girlies, from the SDL 3.4.18 era, and yeah she lives in the SDL_HINT_FRA..._ACCELERATION(3) page, slay βπΈ
π¦ 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