SDL_GetDXGIOutputInfo(3)
๐ SDL_GetDXGIOutputInfo ๐
okay bestie, welcome to the SDL3 FUNCTIONS corner of the man pages โ this one is SDL_GetDXGIOutputInfo(3) and it's lowkey niche but highkey useful if you're doing Windows graphics stuff. Windows only vibes, iykyk. ๐ชโจ
๐ธ NAME ๐ธ
SDL_GetDXGIOutputInfo โ grab the DXGI Adapter and Output indices for the display you're pointing at. that's the whole job. slay.
๐ SYNOPSIS ๐
#include <SDL3/SDL_system.h>
bool SDL_GetDXGIOutputInfo(SDL_DisplayID displayID, int *adapterIndex, int *outputIndex);
like. three args. one bool. we love a clean signature. ๐
๐ฆ DESCRIPTION ๐ฆ
so here's the tea: once you have those DXGI Adapter and Output indices, you can pass them to EnumAdapters and EnumOutputs respectively โ and that's how you get the objects you need to create a DX10 or DX11 device and swap chain. ๐ฎ
basically it's the little bridge between SDL knowing about your display and DirectX knowing about your display. not me being the middleman of the graphics pipeline fr fr. ๐ญ
โจ FUNCTION PARAMETERS โจ
displayIDโ the instance of the display you wanna query. which screen, bestie. ๐adapterIndexโ a pointer that gets filled in with the adapter index. it's giving "you hand me a pointer, I hand you the answer." ๐ซถoutputIndexโ a pointer that gets filled in with the output index. same deal, different number. ๐
๐ RETURN VALUE ๐
returns true on success or false on failure. and if it fails? call SDL_GetError() for more information โ she will tell you what went wrong, no cap. ๐ข
๐ AVAILABILITY ๐
this function is available since SDL 3.2.0. so if you're on something older... girl. upgrade. ๐
๐ก quick reminder: every single one of these details matters โ the pointer types, thetrue/false, theSDL_GetError()call โ so don't get cute and skip them, mwah. ๐
sign-off time ๐โจ this page came to you from Simple Directmedia Layer, version SDL 3.4.18, dated with the very same <rainbow>SDL_GetDXGIOutputInfo(3)</rainbow> energy it started with. stan the man pages, bestie, they love you. ๐๐ฆ๐
๐ฆ 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