SDL_GetGamepadVendor(3)

πŸ’– SDL_GetGamepadVendor(3) πŸ’–

okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, this one lives in SDL_GetGamepadVendor(3) and it's genuinely so simple you're gonna slay it πŸŽ€


✨ NAME ✨

SDL_GetGamepadVendor β€” grab the USB vendor ID of a gamepad you've already opened, if it's available πŸ’…


🌸 SYNOPSIS 🌸

#include <SDL3/SDL_gamepad.h>

Uint16 SDL_GetGamepadVendor(SDL_Gamepad *gamepad);

πŸ¦‹ DESCRIPTION πŸ¦‹

so like, you hand it a gamepad, it hands you back the vendor ID. that's the whole vibe 🫢

but lowkey, if the vendor ID isn't available, this function just returns 0. no drama, no error, just a zero. noted. πŸ’€

πŸŽ€ FUNCTION PARAMETERS πŸŽ€

  • gamepad β€” the gamepad object you wanna query, bestie. that's it, that's the whole input. ✨

πŸ’œ RETURN VALUE πŸ’œ

returns the USB vendor ID, or zero if it's unavailable. no cap.


πŸ”₯ THREAD SAFETY πŸ”₯

it is safe to call this function from any thread. go off, queen πŸ‘‘ β€” thread it from wherever, it's fine.


🌈 AVAILABILITY 🌈

this function has been available since SDL 3.2.0. it's giving established. ⭐


πŸ’« SEE ALSO πŸ’«


and that's the whole page, periodt πŸ’– written up for Simple Directmedia Layer, version SDL 3.4.18 β€” and yeah, the original footer's date slot is just chillin' empty, so consider this your cute lil sign-off instead. bye bestie, go query some gamepads πŸŽ€βœ¨πŸŒΈ

πŸ“¦ where this page comes from