SDL_UpdateGamepads(3)
SDL_UpdateGamepads(3) ๐
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, where we manually pump gamepad updates like it's our job (because, in this one specific case, it literally is) ๐ฎโจ
โจ NAME โจ
SDL_UpdateGamepads โ the girlies who are not using the loop get to manually pump gamepad updates, and honestly? slay ๐ซถ
๐ธ SYNOPSIS ๐ธ
#include <SDL3/SDL_gamepad.h>
void SDL_UpdateGamepads(void);
no arguments, no return value, just vibes and a void ๐
๐ฆ DESCRIPTION ๐ฆ
so here's the tea, bestie โ โ this function is called automatically by the event loop if events are enabled. like, it just happens, no effort required, main character energy fr fr.
under such circumstances (iykyk), it will not be necessary to call this function. so if your event loop is already doing its thing with events enabled, you can just... not. let it cook. ๐ฅ
it's giving "the event loop already handles this for you" and it's iconic for that.
๐ THREAD SAFETY ๐
good news, bestie โ it is safe to call this function from any thread. every single one. no cap. call it from whatever thread you want, she does not care ๐ง๐
๐ AVAILABILITY ๐
this function is available since SDL 3.2.0. so if you're on anything older than that, sorry babe, this one's not for you ๐ญ
vibe check reminder: if events are enabled, the event loop is already pumping these updates for you. calling it anyway isn't the move โ it's just unnecessary. ๐ซถ
and that's the whole page, periodt. this lil love letter came to you from Simple Directmedia Layer, version SDL 3.4.18, dated at the bottom as SDL_UpdateGamepads(3) ๐ mwah, go update those gamepads bestie ๐ โจ๐
๐ฆ 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