SDL_HINT_TV_REMOTE_AS_JOYSTICK(3)
๐ SDL_HINT_TV_REMOTE_AS_JOYSTICK ๐
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, where we're talking about one very specific little hint: SDL_HINT_TV_REMOTE_AS_JOYSTICK. she's a variable, she controls a vibe, and she is lowkey iconic for it. let's get into it ๐
โจ NAME โจ
SDL_HINT_TV_REMOTE_AS_JOYSTICK โ a variable controlling whether the Android / tvOS remotes should be listed as joystick devices, instead of sending keyboard events.
like. it decides if your remote gets to be a joystick or a keyboard. that's the whole thing. no cap. ๐น๏ธ
๐ฆ SYNOPSIS ๐ฆ
#include <SDL3/SDL_hints.h>
#define SDL_HINT_TV_REMOTE_AS_JOYSTICK "SDL_TV_REMOTE_AS_JOYSTICK"
so you pull in the header, and the hint name itself literally spells out as the string "SDL_TV_REMOTE_AS_JOYSTICK". cute, consistent, we love a self-documenting macro ๐
๐ธ DESCRIPTION ๐ธ
okay so here's the tea โ โ this variable can be set to the following values:
"0"โ Remotes send enter/escape/arrow key events. so your remote is out here typing at you like a lil keyboard. classic. โจ๏ธ"1"โ Remotes are available as 2 axis, 2 button joysticks. this is the default, bestie, so if you don't touch anything this is what you get. two axes, two buttons, joystick era. ๐ฎโจ
important timing note: this hint should be set before SDL is initialized. set it late and it's giving "oops", so do it early, okay? ๐ซถ
โญ AVAILABILITY โญ
this hint is available since SDL 3.2.0. she's been around a minute, she's settled, she's thriving. ๐
and that's the whole page, babes ๐ โ brought to you by Simple Directmedia Layer, SDL 3.4.18, and this very SDL_HINT_TV_REMOTE_AS_JOYSTICK(3) moment. go set your hint early, slay your remote setup, and remember: joystick by default, keyboard if you say so. mwah ๐๐๐ฆ
๐ฆ 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