SDL_HINT_HIDAPI_IGNORE_DEVICES(3)
β¨ SDL_HINT_HIDAPI_IGNORE_DEVICES β¨
okay bestie, welcome to another episode of the SDL3 functions manpage saga π this one lives in the SDL3 FUNCTIONS corner of the manual and it's literally about telling SDL which USB devices to pretend don't exist. iconic behaviour honestly π
πΈ NAME πΈ
SDL_HINT_HIDAPI_IGNORE_DEVICES β a variable containing a list of devices to ignore in SDL_hid_enumerate().
no cap, that's the whole vibe. you hand it a list, SDL skips those devices like they're not in the group chat π«Ά
π¦ SYNOPSIS π¦
#include <SDL3/SDL_hints.h>
#define SDL_HINT_HIDAPI_IGNORE_DEVICES "SDL_HIDAPI_IGNORE_DEVICES"
π DESCRIPTION π
so the format of the string is a comma separated list of USB VID/PID pairs in hexadecimal form, like this:
0xAAAA/0xBBBB,0xCCCC/0xDDDD
each pair is a vendor ID and a product ID, slash between them, commas between the pairs. simple. clean. slay β¨
for example, if you wanted to ignore the Shanwan DS3 controller and any Valve controller, you might use the string:
"0x2563/0x0523,0x28de/0x0000"
π«Ά this hint can be set anytime. no timing drama, no "only before init" nonsense. set it whenever, bestie.
π AVAILABILITY π
this hint is available since SDL 3.2.0. if you're on anything older, it's giving "not invited to the party" π
and that's the tea π this page came to you from the lovely people at Simple Directmedia Layer, and it's from the SDL 3.4.18 era of the docs. go forth and ignore some devices, bestie, you've got this π
π¦ 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