SDL 3.0
SDL_hints.h
Go to the documentation of this file.
1/*
2 Simple DirectMedia Layer
3 Copyright (C) 1997-2026 Sam Lantinga <slouken@libsdl.org>
4
5 This software is provided 'as-is', without any express or implied
6 warranty. In no event will the authors be held liable for any damages
7 arising from the use of this software.
8
9 Permission is granted to anyone to use this software for any purpose,
10 including commercial applications, and to alter it and redistribute it
11 freely, subject to the following restrictions:
12
13 1. The origin of this software must not be misrepresented; you must not
14 claim that you wrote the original software. If you use this software
15 in a product, an acknowledgment in the product documentation would be
16 appreciated but is not required.
17 2. Altered source versions must be plainly marked as such, and must not be
18 misrepresented as being the original software.
19 3. This notice may not be removed or altered from any source distribution.
20*/
21
22/**
23 * # CategoryHints
24 *
25 * This file contains functions to set and get configuration hints, as well as
26 * listing each of them alphabetically.
27 *
28 * The convention for naming hints is SDL_HINT_X, where "SDL_X" is the
29 * environment variable that can be used to override the default.
30 *
31 * In general these hints are just that - they may or may not be supported or
32 * applicable on any given platform, but they provide a way for an application
33 * or user to give the library a hint as to how they would like the library to
34 * work.
35 */
36
37#ifndef SDL_hints_h_
38#define SDL_hints_h_
39
40#include <SDL3/SDL_error.h>
41#include <SDL3/SDL_stdinc.h>
42
43#include <SDL3/SDL_begin_code.h>
44/* Set up for C function definitions, even when using C++ */
45#ifdef __cplusplus
46extern "C" {
47#endif
48
49/**
50 * Specify the behavior of Alt+Tab while the keyboard is grabbed.
51 *
52 * By default, SDL emulates Alt+Tab functionality while the keyboard is
53 * grabbed and your window is full-screen. This prevents the user from getting
54 * stuck in your application if you've enabled keyboard grab.
55 *
56 * The variable can be set to the following values:
57 *
58 * - "0": SDL will not handle Alt+Tab. Your application is responsible for
59 * handling Alt+Tab while the keyboard is grabbed.
60 * - "1": SDL will minimize your window when Alt+Tab is pressed (default)
61 *
62 * This hint can be set anytime.
63 *
64 * \since This hint is available since SDL 3.2.0.
65 */
66#define SDL_HINT_ALLOW_ALT_TAB_WHILE_GRABBED "SDL_ALLOW_ALT_TAB_WHILE_GRABBED"
67
68/**
69 * A variable to control whether the SDL activity is allowed to be re-created.
70 *
71 * If this hint is true, the activity can be recreated on demand by the OS,
72 * and Java static data and C++ static data remain with their current values.
73 * If this hint is false, then SDL will call exit() when you return from your
74 * main function and the application will be terminated and then started fresh
75 * each time.
76 *
77 * The variable can be set to the following values:
78 *
79 * - "0": The application starts fresh at each launch. (default)
80 * - "1": The application activity can be recreated by the OS.
81 *
82 * This hint can be set anytime.
83 *
84 * \since This hint is available since SDL 3.2.0.
85 */
86#define SDL_HINT_ANDROID_ALLOW_RECREATE_ACTIVITY "SDL_ANDROID_ALLOW_RECREATE_ACTIVITY"
87
88/**
89 * A variable to control whether the event loop will block itself when the app
90 * is paused.
91 *
92 * The variable can be set to the following values:
93 *
94 * - "0": Non blocking.
95 * - "1": Blocking. (default)
96 *
97 * This hint should be set before SDL is initialized.
98 *
99 * \since This hint is available since SDL 3.2.0.
100 */
101#define SDL_HINT_ANDROID_BLOCK_ON_PAUSE "SDL_ANDROID_BLOCK_ON_PAUSE"
102
103/**
104 * A variable to control whether low latency audio should be enabled.
105 *
106 * Some devices have poor quality output when this is enabled, but this is
107 * usually an improvement in audio latency.
108 *
109 * The variable can be set to the following values:
110 *
111 * - "0": Low latency audio is not enabled.
112 * - "1": Low latency audio is enabled. (default)
113 *
114 * This hint should be set before SDL audio is initialized.
115 *
116 * \since This hint is available since SDL 3.2.0.
117 */
118#define SDL_HINT_ANDROID_LOW_LATENCY_AUDIO "SDL_ANDROID_LOW_LATENCY_AUDIO"
119
120/**
121 * A variable to control whether we trap the Android back button to handle it
122 * manually.
123 *
124 * This is necessary for the right mouse button to work on some Android
125 * devices, or to be able to trap the back button for use in your code
126 * reliably. If this hint is true, the back button will show up as an
127 * SDL_EVENT_KEY_DOWN / SDL_EVENT_KEY_UP pair with a keycode of
128 * SDL_SCANCODE_AC_BACK.
129 *
130 * The variable can be set to the following values:
131 *
132 * - "0": Back button will be handled as usual for system. (default)
133 * - "1": Back button will be trapped, allowing you to handle the key press
134 * manually. (This will also let right mouse click work on systems where the
135 * right mouse button functions as back.)
136 *
137 * This hint can be set anytime.
138 *
139 * \since This hint is available since SDL 3.2.0.
140 */
141#define SDL_HINT_ANDROID_TRAP_BACK_BUTTON "SDL_ANDROID_TRAP_BACK_BUTTON"
142
143/**
144 * A variable to control whether we allow persistent folder access on Android
145 * when using the SDL select folder dialog.
146 *
147 * If set to `1`, the selected folder will be accessible persistently across
148 * app launches. That allows the user to only have to select the directory
149 * once, and then the app can access it again in the future without needing to
150 * ask the user to select it again.
151 *
152 * The variable can be set to the following values:
153 *
154 * - "0": Persistent folder access is not allowed. (default)
155 * - "1": Persistent folder access is allowed.
156 *
157 * This hint should be set before the SDL folder selection dialog is shown,
158 * and can be changed between dialog invocations.
159 *
160 * \since This hint is available since SDL 3.6.0.
161 */
162#define SDL_HINT_ANDROID_ALLOW_PERSISTENT_FOLDER_ACCESS "SDL_ANDROID_ALLOW_PERSISTENT_FOLDER_ACCESS"
163
164/**
165 * A variable setting the app ID string.
166 *
167 * This string is used by desktop compositors to identify and group windows
168 * together, as well as match applications with associated desktop settings
169 * and icons.
170 *
171 * This will override SDL_PROP_APP_METADATA_IDENTIFIER_STRING, if set by the
172 * application.
173 *
174 * This hint should be set before SDL is initialized.
175 *
176 * \since This hint is available since SDL 3.2.0.
177 */
178#define SDL_HINT_APP_ID "SDL_APP_ID"
179
180/**
181 * A variable setting the application name.
182 *
183 * This hint lets you specify the application name sent to the OS when
184 * required. For example, this will often appear in volume control applets for
185 * audio streams, and in lists of applications which are inhibiting the
186 * screensaver. You should use a string that describes your program ("My Game
187 * 2: The Revenge")
188 *
189 * This will override SDL_PROP_APP_METADATA_NAME_STRING, if set by the
190 * application.
191 *
192 * This hint should be set before SDL is initialized.
193 *
194 * \since This hint is available since SDL 3.2.0.
195 */
196#define SDL_HINT_APP_NAME "SDL_APP_NAME"
197
198/**
199 * A variable controlling whether controllers used with the Apple TV generate
200 * UI events.
201 *
202 * When UI events are generated by controller input, the app will be
203 * backgrounded when the Apple TV remote's menu button is pressed, and when
204 * the pause or B buttons on gamepads are pressed.
205 *
206 * More information about properly making use of controllers for the Apple TV
207 * can be found here:
208 * https://developer.apple.com/tvos/human-interface-guidelines/remote-and-controllers/
209 *
210 * The variable can be set to the following values:
211 *
212 * - "0": Controller input does not generate UI events. (default)
213 * - "1": Controller input generates UI events.
214 *
215 * This hint can be set anytime.
216 *
217 * \since This hint is available since SDL 3.2.0.
218 */
219#define SDL_HINT_APPLE_TV_CONTROLLER_UI_EVENTS "SDL_APPLE_TV_CONTROLLER_UI_EVENTS"
220
221/**
222 * A variable controlling whether the Apple TV remote's joystick axes will
223 * automatically match the rotation of the remote.
224 *
225 * The variable can be set to the following values:
226 *
227 * - "0": Remote orientation does not affect joystick axes. (default)
228 * - "1": Joystick axes are based on the orientation of the remote.
229 *
230 * This hint can be set anytime.
231 *
232 * \since This hint is available since SDL 3.2.0.
233 */
234#define SDL_HINT_APPLE_TV_REMOTE_ALLOW_ROTATION "SDL_APPLE_TV_REMOTE_ALLOW_ROTATION"
235
236/**
237 * Specify the default ALSA audio device name.
238 *
239 * This variable is a specific audio device to open when the "default" audio
240 * device is used.
241 *
242 * This hint will be ignored when opening the default playback device if
243 * SDL_HINT_AUDIO_ALSA_DEFAULT_PLAYBACK_DEVICE is set, or when opening the
244 * default recording device if SDL_HINT_AUDIO_ALSA_DEFAULT_RECORDING_DEVICE is
245 * set.
246 *
247 * This hint should be set before an audio device is opened.
248 *
249 * \since This hint is available since SDL 3.2.0.
250 *
251 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_PLAYBACK_DEVICE
252 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_RECORDING_DEVICE
253 */
254#define SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE "SDL_AUDIO_ALSA_DEFAULT_DEVICE"
255
256/**
257 * Specify the default ALSA audio playback device name.
258 *
259 * This variable is a specific audio device to open for playback, when the
260 * "default" audio device is used.
261 *
262 * If this hint isn't set, SDL will check SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE
263 * before choosing a reasonable default.
264 *
265 * This hint should be set before an audio device is opened.
266 *
267 * \since This hint is available since SDL 3.2.0.
268 *
269 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_RECORDING_DEVICE
270 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE
271 */
272#define SDL_HINT_AUDIO_ALSA_DEFAULT_PLAYBACK_DEVICE "SDL_AUDIO_ALSA_DEFAULT_PLAYBACK_DEVICE"
273
274/**
275 * Specify the default ALSA audio recording device name.
276 *
277 * This variable is a specific audio device to open for recording, when the
278 * "default" audio device is used.
279 *
280 * If this hint isn't set, SDL will check SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE
281 * before choosing a reasonable default.
282 *
283 * This hint should be set before an audio device is opened.
284 *
285 * \since This hint is available since SDL 3.2.0.
286 *
287 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_PLAYBACK_DEVICE
288 * \sa SDL_HINT_AUDIO_ALSA_DEFAULT_DEVICE
289 */
290#define SDL_HINT_AUDIO_ALSA_DEFAULT_RECORDING_DEVICE "SDL_AUDIO_ALSA_DEFAULT_RECORDING_DEVICE"
291
292/**
293 * A variable controlling the audio category on iOS and macOS.
294 *
295 * The variable can be set to the following values:
296 *
297 * - "playback": Use the AVAudioSessionCategoryPlayback category. (default)
298 * - "ambient": Use the AVAudioSessionCategoryAmbient audio category, will be
299 * muted by the phone mute switch.
300 *
301 * For more information, see Apple's documentation:
302 * https://developer.apple.com/library/content/documentation/Audio/Conceptual/AudioSessionProgrammingGuide/AudioSessionCategoriesandModes/AudioSessionCategoriesandModes.html
303 *
304 * This hint should be set before an audio device is opened.
305 *
306 * \since This hint is available since SDL 3.2.0.
307 */
308#define SDL_HINT_AUDIO_CATEGORY "SDL_AUDIO_CATEGORY"
309
310/**
311 * A variable controlling the default audio channel count.
312 *
313 * If the application doesn't specify the audio channel count when opening the
314 * device, this hint can be used to specify a default channel count that will
315 * be used. This defaults to "1" for recording and "2" for playback devices.
316 *
317 * This hint should be set before an audio device is opened.
318 *
319 * \since This hint is available since SDL 3.2.0.
320 */
321#define SDL_HINT_AUDIO_CHANNELS "SDL_AUDIO_CHANNELS"
322
323/**
324 * Specify an application icon name for an audio device.
325 *
326 * Some audio backends (such as Pulseaudio and Pipewire) allow you to set an
327 * XDG icon name for your application. Among other things, this icon might
328 * show up in a system control panel that lets the user adjust the volume on
329 * specific audio streams instead of using one giant master volume slider.
330 * Note that this is unrelated to the icon used by the windowing system, which
331 * may be set with SDL_SetWindowIcon (or via desktop file on Wayland).
332 *
333 * Setting this to "" or leaving it unset will have SDL use a reasonable
334 * default, "applications-games", which is likely to be installed. See
335 * https://specifications.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html
336 * and
337 * https://specifications.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html
338 * for the relevant XDG icon specs.
339 *
340 * This hint should be set before an audio device is opened.
341 *
342 * \since This hint is available since SDL 3.2.0.
343 */
344#define SDL_HINT_AUDIO_DEVICE_APP_ICON_NAME "SDL_AUDIO_DEVICE_APP_ICON_NAME"
345
346/**
347 * A variable controlling device buffer size.
348 *
349 * This hint is an integer > 0, that represents the size of the device's
350 * buffer in sample frames (stereo audio data in 16-bit format is 4 bytes per
351 * sample frame, for example).
352 *
353 * SDL3 generally decides this value on behalf of the app, but if for some
354 * reason the app needs to dictate this (because they want either lower
355 * latency or higher throughput AND ARE WILLING TO DEAL WITH what that might
356 * require of the app), they can specify it.
357 *
358 * SDL will try to accommodate this value, but there is no promise you'll get
359 * the buffer size requested. Many platforms won't honor this request at all,
360 * or might adjust it.
361 *
362 * This hint should be set before an audio device is opened.
363 *
364 * \since This hint is available since SDL 3.2.0.
365 */
366#define SDL_HINT_AUDIO_DEVICE_SAMPLE_FRAMES "SDL_AUDIO_DEVICE_SAMPLE_FRAMES"
367
368/**
369 * Specify an audio stream name for an audio device.
370 *
371 * Some audio backends (such as PulseAudio) allow you to describe your audio
372 * stream. Among other things, this description might show up in a system
373 * control panel that lets the user adjust the volume on specific audio
374 * streams instead of using one giant master volume slider.
375 *
376 * This hints lets you transmit that information to the OS. The contents of
377 * this hint are used while opening an audio device. You should use a string
378 * that describes your what your program is playing ("audio stream" is
379 * probably sufficient in many cases, but this could be useful for something
380 * like "team chat" if you have a headset playing VoIP audio separately).
381 *
382 * Setting this to "" or leaving it unset will have SDL use a reasonable
383 * default: "audio stream" or something similar.
384 *
385 * Note that while this talks about audio streams, this is an OS-level
386 * concept, so it applies to a physical audio device in this case, and not an
387 * SDL_AudioStream, nor an SDL logical audio device.
388 *
389 * This hint should be set before an audio device is opened.
390 *
391 * \since This hint is available since SDL 3.2.0.
392 */
393#define SDL_HINT_AUDIO_DEVICE_STREAM_NAME "SDL_AUDIO_DEVICE_STREAM_NAME"
394
395/**
396 * Specify an application role for an audio device.
397 *
398 * Some audio backends (such as Pipewire) allow you to describe the role of
399 * your audio stream. Among other things, this description might show up in a
400 * system control panel or software for displaying and manipulating media
401 * playback/recording graphs.
402 *
403 * This hints lets you transmit that information to the OS. The contents of
404 * this hint are used while opening an audio device. You should use a string
405 * that describes your what your program is playing (Game, Music, Movie,
406 * etc...).
407 *
408 * Setting this to "" or leaving it unset will have SDL use a reasonable
409 * default: "Game" or something similar.
410 *
411 * Note that while this talks about audio streams, this is an OS-level
412 * concept, so it applies to a physical audio device in this case, and not an
413 * SDL_AudioStream, nor an SDL logical audio device.
414 *
415 * For Windows WASAPI audio, the following roles are supported, and map to
416 * `AUDIO_STREAM_CATEGORY`:
417 *
418 * - "Other" (default)
419 * - "Communications" - Real-time communications, such as VOIP or chat
420 * - "Game" - Game audio
421 * - "GameChat" - Game chat audio, similar to "Communications" except that
422 * this will not attenuate other audio streams
423 * - "Movie" - Music or sound with dialog
424 * - "Media" - Music or sound without dialog
425 *
426 * Android's AAudio target supports this hint as of SDL 3.4.4. Android does
427 * not support the exact same options as WASAPI, but for portability, will
428 * attempt to map these same strings to the `aaudio_usage_t` constants. For
429 * example, "Movie" and "Media" will both map to `AAUDIO_USAGE_MEDIA`, etc.
430 *
431 * If your application applies its own echo cancellation, gain control, and
432 * noise reduction it should also set SDL_HINT_AUDIO_DEVICE_RAW_STREAM.
433 *
434 * This hint should be set before an audio device is opened.
435 *
436 * \since This hint is available since SDL 3.2.0.
437 */
438#define SDL_HINT_AUDIO_DEVICE_STREAM_ROLE "SDL_AUDIO_DEVICE_STREAM_ROLE"
439
440/**
441 * Specify whether this audio device should do audio processing.
442 *
443 * Some operating systems perform echo cancellation, gain control, and noise
444 * reduction as needed. If your application already handles these, you can set
445 * this hint to prevent the OS from doing additional audio processing.
446 *
447 * This corresponds to the WASAPI audio option `AUDCLNT_STREAMOPTIONS_RAW`.
448 *
449 * The variable can be set to the following values:
450 *
451 * - "0": audio processing can be done by the OS. (default)
452 * - "1": audio processing is done by the application.
453 *
454 * This hint should be set before an audio device is opened.
455 *
456 * \since This hint is available since SDL 3.4.0.
457 */
458#define SDL_HINT_AUDIO_DEVICE_RAW_STREAM "SDL_AUDIO_DEVICE_RAW_STREAM"
459
460/**
461 * Specify the input file when recording audio using the disk audio driver.
462 *
463 * This defaults to "sdlaudio-in.raw"
464 *
465 * This hint should be set before an audio device is opened.
466 *
467 * \since This hint is available since SDL 3.2.0.
468 */
469#define SDL_HINT_AUDIO_DISK_INPUT_FILE "SDL_AUDIO_DISK_INPUT_FILE"
470
471/**
472 * Specify the output file when playing audio using the disk audio driver.
473 *
474 * This defaults to "sdlaudio.raw"
475 *
476 * This hint should be set before an audio device is opened.
477 *
478 * \since This hint is available since SDL 3.2.0.
479 */
480#define SDL_HINT_AUDIO_DISK_OUTPUT_FILE "SDL_AUDIO_DISK_OUTPUT_FILE"
481
482/**
483 * A variable controlling the audio rate when using the disk audio driver.
484 *
485 * The disk audio driver normally simulates real-time for the audio rate that
486 * was specified, but you can use this variable to adjust this rate higher or
487 * lower down to 0. The default value is "1.0".
488 *
489 * This hint should be set before an audio device is opened.
490 *
491 * \since This hint is available since SDL 3.2.0.
492 */
493#define SDL_HINT_AUDIO_DISK_TIMESCALE "SDL_AUDIO_DISK_TIMESCALE"
494
495/**
496 * A variable that specifies an audio backend to use.
497 *
498 * By default, SDL will try all available audio backends in a reasonable order
499 * until it finds one that can work, but this hint allows the app or user to
500 * force a specific driver, such as "pipewire" if, say, you are on PulseAudio
501 * but want to try talking to the lower level instead.
502 *
503 * This hint should be set before SDL is initialized.
504 *
505 * \since This hint is available since SDL 3.2.0.
506 */
507#define SDL_HINT_AUDIO_DRIVER "SDL_AUDIO_DRIVER"
508
509/**
510 * Specify whether this audio stream should duck other audio.
511 *
512 * On Apple platforms, this hint controls whether other audio streams are
513 * ducked (reduced in volume) while your application is in the foreground.
514 *
515 * The variable can be set to the following values:
516 *
517 * - "0": Other audio will not be ducked. (default)
518 * - "1": Other audio will be ducked.
519 *
520 * This hint should be set before an audio device is opened.
521 *
522 * \since This hint is available since SDL 3.6.0.
523 */
524#define SDL_HINT_AUDIO_DUCK_OTHERS "SDL_AUDIO_DUCK_OTHERS"
525
526/**
527 * A variable controlling the audio rate when using the dummy audio driver.
528 *
529 * The dummy audio driver normally simulates real-time for the audio rate that
530 * was specified, but you can use this variable to adjust this rate higher or
531 * lower down to 0. The default value is "1.0".
532 *
533 * This hint should be set before an audio device is opened.
534 *
535 * \since This hint is available since SDL 3.2.0.
536 */
537#define SDL_HINT_AUDIO_DUMMY_TIMESCALE "SDL_AUDIO_DUMMY_TIMESCALE"
538
539/**
540 * A variable controlling the default audio format.
541 *
542 * If the application doesn't specify the audio format when opening the
543 * device, this hint can be used to specify a default format that will be
544 * used.
545 *
546 * The variable can be set to the following values:
547 *
548 * - "U8": Unsigned 8-bit audio
549 * - "S8": Signed 8-bit audio
550 * - "S16LE": Signed 16-bit little-endian audio
551 * - "S16BE": Signed 16-bit big-endian audio
552 * - "S16": Signed 16-bit native-endian audio (default)
553 * - "S32LE": Signed 32-bit little-endian audio
554 * - "S32BE": Signed 32-bit big-endian audio
555 * - "S32": Signed 32-bit native-endian audio
556 * - "F32LE": Floating point little-endian audio
557 * - "F32BE": Floating point big-endian audio
558 * - "F32": Floating point native-endian audio
559 *
560 * This hint should be set before an audio device is opened.
561 *
562 * \since This hint is available since SDL 3.2.0.
563 */
564#define SDL_HINT_AUDIO_FORMAT "SDL_AUDIO_FORMAT"
565
566/**
567 * A variable controlling the default audio frequency.
568 *
569 * If the application doesn't specify the audio frequency when opening the
570 * device, this hint can be used to specify a default frequency that will be
571 * used. This defaults to "44100".
572 *
573 * This hint should be set before an audio device is opened.
574 *
575 * \since This hint is available since SDL 3.2.0.
576 */
577#define SDL_HINT_AUDIO_FREQUENCY "SDL_AUDIO_FREQUENCY"
578
579/**
580 * A variable that causes SDL to not ignore audio "monitors".
581 *
582 * This is currently only used by the PulseAudio driver.
583 *
584 * By default, SDL ignores audio devices that aren't associated with physical
585 * hardware. Changing this hint to "1" will expose anything SDL sees that
586 * appears to be an audio source or sink. This will add "devices" to the list
587 * that the user probably doesn't want or need, but it can be useful in
588 * scenarios where you want to hook up SDL to some sort of virtual device,
589 * etc.
590 *
591 * The variable can be set to the following values:
592 *
593 * - "0": Audio monitor devices will be ignored. (default)
594 * - "1": Audio monitor devices will show up in the device list.
595 *
596 * This hint should be set before SDL is initialized.
597 *
598 * \since This hint is available since SDL 3.2.0.
599 */
600#define SDL_HINT_AUDIO_INCLUDE_MONITORS "SDL_AUDIO_INCLUDE_MONITORS"
601
602/**
603 * A variable controlling whether SDL updates joystick state when getting
604 * input events.
605 *
606 * The variable can be set to the following values:
607 *
608 * - "0": You'll call SDL_UpdateJoysticks() manually.
609 * - "1": SDL will automatically call SDL_UpdateJoysticks(). (default)
610 *
611 * This hint can be set anytime.
612 *
613 * \since This hint is available since SDL 3.2.0.
614 */
615#define SDL_HINT_AUTO_UPDATE_JOYSTICKS "SDL_AUTO_UPDATE_JOYSTICKS"
616
617/**
618 * A variable controlling whether SDL updates sensor state when getting input
619 * events.
620 *
621 * The variable can be set to the following values:
622 *
623 * - "0": You'll call SDL_UpdateSensors() manually.
624 * - "1": SDL will automatically call SDL_UpdateSensors(). (default)
625 *
626 * This hint can be set anytime.
627 *
628 * \since This hint is available since SDL 3.2.0.
629 */
630#define SDL_HINT_AUTO_UPDATE_SENSORS "SDL_AUTO_UPDATE_SENSORS"
631
632/**
633 * Prevent SDL from using version 4 of the bitmap header when saving BMPs.
634 *
635 * The bitmap header version 4 is required for proper alpha channel support
636 * and SDL will use it when required. Should this not be desired, this hint
637 * can force the use of the 40 byte header version which is supported
638 * everywhere.
639 *
640 * The variable can be set to the following values:
641 *
642 * - "0": Surfaces with a colorkey or an alpha channel are saved to a 32-bit
643 * BMP file with an alpha mask. SDL will use the bitmap header version 4 and
644 * set the alpha mask accordingly. (default)
645 * - "1": Surfaces with a colorkey or an alpha channel are saved to a 32-bit
646 * BMP file without an alpha mask. The alpha channel data will be in the
647 * file, but applications are going to ignore it.
648 *
649 * This hint can be set anytime.
650 *
651 * \since This hint is available since SDL 3.2.0.
652 */
653#define SDL_HINT_BMP_SAVE_LEGACY_FORMAT "SDL_BMP_SAVE_LEGACY_FORMAT"
654
655/**
656 * A variable that decides what camera backend to use.
657 *
658 * By default, SDL will try all available camera backends in a reasonable
659 * order until it finds one that can work, but this hint allows the app or
660 * user to force a specific target, such as "directshow" if, say, you are on
661 * Windows Media Foundations but want to try DirectShow instead.
662 *
663 * The default value is unset, in which case SDL will try to figure out the
664 * best camera backend on your behalf. This hint needs to be set before
665 * SDL_Init() is called to be useful.
666 *
667 * \since This hint is available since SDL 3.2.0.
668 */
669#define SDL_HINT_CAMERA_DRIVER "SDL_CAMERA_DRIVER"
670
671/**
672 * A variable that limits what CPU features are available.
673 *
674 * By default, SDL marks all features the current CPU supports as available.
675 * This hint allows the enabled features to be limited to a subset.
676 *
677 * When the hint is unset, or empty, SDL will enable all detected CPU
678 * features.
679 *
680 * The variable can be set to a comma separated list containing the following
681 * items:
682 *
683 * - "all"
684 * - "altivec"
685 * - "sse"
686 * - "sse2"
687 * - "sse3"
688 * - "sse41"
689 * - "sse42"
690 * - "avx"
691 * - "avx2"
692 * - "avx512f"
693 * - "arm-simd"
694 * - "neon"
695 * - "sve2"
696 * - "lsx"
697 * - "lasx"
698 *
699 * The items can be prefixed by '+'/'-' to add/remove features.
700 *
701 * \since This hint is available since SDL 3.2.0.
702 */
703#define SDL_HINT_CPU_FEATURE_MASK "SDL_CPU_FEATURE_MASK"
704
705/**
706 * A variable controlling whether DirectInput should be used for controllers.
707 *
708 * The variable can be set to the following values:
709 *
710 * - "0": Disable DirectInput detection.
711 * - "1": Enable DirectInput detection. (default)
712 *
713 * This hint should be set before SDL is initialized.
714 *
715 * \since This hint is available since SDL 3.2.0.
716 */
717#define SDL_HINT_JOYSTICK_DIRECTINPUT "SDL_JOYSTICK_DIRECTINPUT"
718
719/**
720 * A variable that specifies a dialog backend to use.
721 *
722 * By default, SDL will try all available dialog backends in a reasonable
723 * order until it finds one that can work, but this hint allows the app or
724 * user to force a specific target.
725 *
726 * If the specified target does not exist or is not available, the
727 * dialog-related function calls will fail.
728 *
729 * This hint currently only applies to platforms using the generic "Unix"
730 * dialog implementation, but may be extended to more platforms in the future.
731 * Note that some Unix and Unix-like platforms have their own implementation,
732 * such as macOS and Haiku.
733 *
734 * The variable can be set to the following values:
735 *
736 * - NULL: Select automatically (default, all platforms)
737 * - "portal": Use XDG Portals through DBus (Unix only)
738 * - "zenity": Use the Zenity program (Unix only)
739 *
740 * More options may be added in the future.
741 *
742 * This hint can be set anytime.
743 *
744 * \since This hint is available since SDL 3.2.0.
745 */
746#define SDL_HINT_FILE_DIALOG_DRIVER "SDL_FILE_DIALOG_DRIVER"
747
748/**
749 * Override for SDL_GetDisplayUsableBounds().
750 *
751 * If set, this hint will override the expected results for
752 * SDL_GetDisplayUsableBounds() for display index 0. Generally you don't want
753 * to do this, but this allows an embedded system to request that some of the
754 * screen be reserved for other uses when paired with a well-behaved
755 * application.
756 *
757 * The contents of this hint must be 4 comma-separated integers, the first is
758 * the bounds x, then y, width and height, in that order.
759 *
760 * This hint can be set anytime.
761 *
762 * \since This hint is available since SDL 3.2.0.
763 */
764#define SDL_HINT_DISPLAY_USABLE_BOUNDS "SDL_DISPLAY_USABLE_BOUNDS"
765
766/**
767 * A variable that enables a fast framebuffer path on DOS.
768 *
769 * When set to "1", SDL_UpdateWindowSurface() copies the system-RAM surface
770 * directly to VRAM and skips software cursor compositing and vsync.
771 *
772 * The variable can be set to the following values:
773 *
774 * - "0": Use the normal path with cursor compositing and vsync. (default)
775 * - "1": Use the fast direct-to-VRAM path when available.
776 *
777 * This hint must be set before the first call to SDL_GetWindowSurface().
778 *
779 * \since This hint is available since SDL 3.6.0.
780 */
781#define SDL_HINT_DOS_ALLOW_DIRECT_FRAMEBUFFER "SDL_DOS_ALLOW_DIRECT_FRAMEBUFFER"
782
783/**
784 * Set the level of checking for invalid parameters passed to SDL functions.
785 *
786 * The variable can be set to the following values:
787 *
788 * - "1": Enable fast parameter error checking, e.g. quick NULL checks, etc.
789 * - "2": Enable full parameter error checking, e.g. validating objects are
790 * the correct type, etc. (default)
791 *
792 * This hint can be set anytime.
793 *
794 * \since This hint is available since SDL 3.4.0.
795 */
796#define SDL_HINT_INVALID_PARAM_CHECKS "SDL_INVALID_PARAM_CHECKS"
797
798/**
799 * Disable giving back control to the browser automatically when running with
800 * asyncify.
801 *
802 * With -s ASYNCIFY, SDL calls emscripten_sleep during operations such as
803 * refreshing the screen or polling events.
804 *
805 * This hint only applies to the emscripten platform.
806 *
807 * The variable can be set to the following values:
808 *
809 * - "0": Disable emscripten_sleep calls (if you give back browser control
810 * manually or use asyncify for other purposes).
811 * - "1": Enable emscripten_sleep calls. (default)
812 *
813 * This hint can be set anytime.
814 *
815 * \since This hint is available since SDL 3.2.0.
816 */
817#define SDL_HINT_EMSCRIPTEN_ASYNCIFY "SDL_EMSCRIPTEN_ASYNCIFY"
818
819/**
820 * Specify the CSS selector used for the "default" window/canvas.
821 *
822 * This hint only applies to the emscripten platform.
823 *
824 * This hint should be set before creating a window.
825 *
826 * \since This hint is available since SDL 3.2.0.
827 */
828#define SDL_HINT_EMSCRIPTEN_CANVAS_SELECTOR "SDL_EMSCRIPTEN_CANVAS_SELECTOR"
829
830/**
831 * Override the binding element for keyboard inputs for Emscripten builds.
832 *
833 * This hint only applies to the emscripten platform.
834 *
835 * The variable can be one of:
836 *
837 * - "#window": the javascript window object
838 * - "#document": the javascript document object
839 * - "#screen": the javascript window.screen object
840 * - "#canvas": the WebGL canvas element
841 * - "#none": Don't bind anything at all
842 * - any other string without a leading # sign applies to the element on the
843 * page with that ID.
844 *
845 * This hint should be set before creating a window.
846 *
847 * \since This hint is available since SDL 3.2.0.
848 */
849#define SDL_HINT_EMSCRIPTEN_KEYBOARD_ELEMENT "SDL_EMSCRIPTEN_KEYBOARD_ELEMENT"
850
851/**
852 * A variable that controls whether the on-screen keyboard should be shown
853 * when text input is active.
854 *
855 * The variable can be set to the following values:
856 *
857 * - "auto": The on-screen keyboard will be shown if there is no physical
858 * keyboard attached. (default)
859 * - "0": Do not show the on-screen keyboard.
860 * - "1": Show the on-screen keyboard, if available.
861 *
862 * This hint must be set before SDL_StartTextInput() is called
863 *
864 * \since This hint is available since SDL 3.2.0.
865 */
866#define SDL_HINT_ENABLE_SCREEN_KEYBOARD "SDL_ENABLE_SCREEN_KEYBOARD"
867
868/**
869 * A variable that controls whether the Steam on-screen keyboard should be
870 * shown when text input is active.
871 *
872 * Steam will set this hint via environment variable for games launched in Big
873 * Picture mode. To override this you should call SDL_SetHintWithPriority()
874 * with priority `SDL_HINT_OVERRIDE`.
875 *
876 * The variable can be set to the following values:
877 *
878 * - "0": Do not show the Steam on-screen keyboard.
879 * - "1": Show the Steam on-screen keyboard.
880 *
881 * This hint should be set before SDL is initialized.
882 *
883 * \since This hint is available since SDL 3.4.12.
884 */
885#define SDL_HINT_ENABLE_STEAM_SCREEN_KEYBOARD "SDL_ENABLE_STEAM_SCREEN_KEYBOARD"
886
887/**
888 * A variable containing a list of evdev devices to use if udev is not
889 * available.
890 *
891 * The list of devices is in the form:
892 *
893 * deviceclass:path[,deviceclass:path[,...]]
894 *
895 * where device class is an integer representing the SDL_UDEV_deviceclass and
896 * path is the full path to the event device.
897 *
898 * This hint should be set before SDL is initialized.
899 *
900 * \since This hint is available since SDL 3.2.0.
901 */
902#define SDL_HINT_EVDEV_DEVICES "SDL_EVDEV_DEVICES"
903
904/**
905 * A variable controlling verbosity of the logging of SDL events pushed onto
906 * the internal queue.
907 *
908 * The variable can be set to the following values, from least to most
909 * verbose:
910 *
911 * - "0": Don't log any events. (default)
912 * - "1": Log most events (other than the really spammy ones).
913 * - "2": Include mouse and finger motion events.
914 *
915 * This is generally meant to be used to debug SDL itself, but can be useful
916 * for application developers that need better visibility into what is going
917 * on in the event queue. Logged events are sent through SDL_Log(), which
918 * means by default they appear on stdout on most platforms or maybe
919 * OutputDebugString() on Windows, and can be funneled by the app with
920 * SDL_SetLogOutputFunction(), etc.
921 *
922 * This hint can be set anytime.
923 *
924 * \since This hint is available since SDL 3.2.0.
925 */
926#define SDL_HINT_EVENT_LOGGING "SDL_EVENT_LOGGING"
927
928/**
929 * A variable controlling whether raising the window should be done more
930 * forcefully.
931 *
932 * The variable can be set to the following values:
933 *
934 * - "0": Honor the OS policy for raising windows. (default)
935 * - "1": Force the window to be raised, overriding any OS policy.
936 *
937 * At present, this is only an issue under MS Windows, which makes it nearly
938 * impossible to programmatically move a window to the foreground, for
939 * "security" reasons. See http://stackoverflow.com/a/34414846 for a
940 * discussion.
941 *
942 * This hint can be set anytime.
943 *
944 * \since This hint is available since SDL 3.2.0.
945 */
946#define SDL_HINT_FORCE_RAISEWINDOW "SDL_FORCE_RAISEWINDOW"
947
948/**
949 * A variable controlling how 3D acceleration is used to accelerate the SDL
950 * screen surface.
951 *
952 * SDL can try to accelerate the SDL screen surface by using streaming
953 * textures with a 3D rendering engine. This variable controls whether and how
954 * this is done.
955 *
956 * The variable can be set to the following values:
957 *
958 * - "0": Disable 3D acceleration
959 * - "1": Enable 3D acceleration, using the default renderer. (default)
960 * - "X": Enable 3D acceleration, using X where X is one of the valid
961 * rendering drivers. (e.g. "direct3d", "opengl", etc.)
962 *
963 * This hint should be set before calling SDL_GetWindowSurface()
964 *
965 * \since This hint is available since SDL 3.2.0.
966 */
967#define SDL_HINT_FRAMEBUFFER_ACCELERATION "SDL_FRAMEBUFFER_ACCELERATION"
968
969/**
970 * A variable that lets you manually hint extra gamecontroller db entries.
971 *
972 * The variable should be newline delimited rows of gamecontroller config
973 * data, see SDL_gamepad.h
974 *
975 * You can update mappings after SDL is initialized with
976 * SDL_GetGamepadMappingForGUID() and SDL_AddGamepadMapping()
977 *
978 * This hint should be set before SDL is initialized.
979 *
980 * \since This hint is available since SDL 3.2.0.
981 */
982#define SDL_HINT_GAMECONTROLLERCONFIG "SDL_GAMECONTROLLERCONFIG"
983
984/**
985 * A variable that lets you provide a file with extra gamecontroller db
986 * entries.
987 *
988 * The file should contain lines of gamecontroller config data, see
989 * SDL_gamepad.h
990 *
991 * You can update mappings after SDL is initialized with
992 * SDL_GetGamepadMappingForGUID() and SDL_AddGamepadMapping()
993 *
994 * This hint should be set before SDL is initialized.
995 *
996 * \since This hint is available since SDL 3.2.0.
997 */
998#define SDL_HINT_GAMECONTROLLERCONFIG_FILE "SDL_GAMECONTROLLERCONFIG_FILE"
999
1000/**
1001 * A variable that overrides the automatic controller type detection.
1002 *
1003 * The variable should be comma separated entries, in the form: VID/PID=type
1004 *
1005 * The VID and PID should be hexadecimal with exactly 4 digits, e.g. 0x00fd
1006 *
1007 * This hint affects what low level protocol is used with the HIDAPI driver.
1008 *
1009 * The variable can be set to the following values:
1010 *
1011 * - "Xbox360"
1012 * - "XboxOne"
1013 * - "PS3"
1014 * - "PS4"
1015 * - "PS5"
1016 * - "SwitchPro"
1017 *
1018 * This hint should be set before SDL is initialized.
1019 *
1020 * \since This hint is available since SDL 3.2.0.
1021 */
1022#define SDL_HINT_GAMECONTROLLERTYPE "SDL_GAMECONTROLLERTYPE"
1023
1024/**
1025 * A variable containing a list of devices to skip when scanning for game
1026 * controllers.
1027 *
1028 * The format of the string is a comma separated list of USB VID/PID pairs in
1029 * hexadecimal form, e.g.
1030 *
1031 * 0xAAAA/0xBBBB,0xCCCC/0xDDDD
1032 *
1033 * The variable can also take the form of "@file", in which case the named
1034 * file will be loaded and interpreted as the value of the variable.
1035 *
1036 * This hint can be set anytime.
1037 *
1038 * \since This hint is available since SDL 3.2.0.
1039 */
1040#define SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES "SDL_GAMECONTROLLER_IGNORE_DEVICES"
1041
1042/**
1043 * If set, all devices will be skipped when scanning for game controllers
1044 * except for the ones listed in this variable.
1045 *
1046 * The format of the string is a comma separated list of USB VID/PID pairs in
1047 * hexadecimal form, e.g.
1048 *
1049 * 0xAAAA/0xBBBB,0xCCCC/0xDDDD
1050 *
1051 * The variable can also take the form of "@file", in which case the named
1052 * file will be loaded and interpreted as the value of the variable.
1053 *
1054 * This hint can be set anytime.
1055 *
1056 * \since This hint is available since SDL 3.2.0.
1057 */
1058#define SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT "SDL_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT"
1059
1060/**
1061 * A variable that controls whether the device's built-in accelerometer and
1062 * gyro should be used as sensors for gamepads.
1063 *
1064 * The variable can be set to the following values:
1065 *
1066 * - "0": Sensor fusion is disabled
1067 * - "1": Sensor fusion is enabled for all controllers that lack sensors
1068 *
1069 * Or the variable can be a comma separated list of USB VID/PID pairs in
1070 * hexadecimal form, e.g.
1071 *
1072 * 0xAAAA/0xBBBB,0xCCCC/0xDDDD
1073 *
1074 * The variable can also take the form of "@file", in which case the named
1075 * file will be loaded and interpreted as the value of the variable.
1076 *
1077 * This hint should be set before a gamepad is opened.
1078 *
1079 * \since This hint is available since SDL 3.2.0.
1080 */
1081#define SDL_HINT_GAMECONTROLLER_SENSOR_FUSION "SDL_GAMECONTROLLER_SENSOR_FUSION"
1082
1083/**
1084 * This variable sets the default text of the TextInput window on GDK
1085 * platforms.
1086 *
1087 * This hint is available only if SDL_GDK_TEXTINPUT defined.
1088 *
1089 * This hint should be set before calling SDL_StartTextInput()
1090 *
1091 * \since This hint is available since SDL 3.2.0.
1092 */
1093#define SDL_HINT_GDK_TEXTINPUT_DEFAULT_TEXT "SDL_GDK_TEXTINPUT_DEFAULT_TEXT"
1094
1095/**
1096 * This variable sets the description of the TextInput window on GDK
1097 * platforms.
1098 *
1099 * This hint is available only if SDL_GDK_TEXTINPUT defined.
1100 *
1101 * This hint should be set before calling SDL_StartTextInput()
1102 *
1103 * \since This hint is available since SDL 3.2.0.
1104 */
1105#define SDL_HINT_GDK_TEXTINPUT_DESCRIPTION "SDL_GDK_TEXTINPUT_DESCRIPTION"
1106
1107/**
1108 * This variable sets the maximum input length of the TextInput window on GDK
1109 * platforms.
1110 *
1111 * The value must be a stringified integer, for example "10" to allow for up
1112 * to 10 characters of text input.
1113 *
1114 * This hint is available only if SDL_GDK_TEXTINPUT defined.
1115 *
1116 * This hint should be set before calling SDL_StartTextInput()
1117 *
1118 * \since This hint is available since SDL 3.2.0.
1119 */
1120#define SDL_HINT_GDK_TEXTINPUT_MAX_LENGTH "SDL_GDK_TEXTINPUT_MAX_LENGTH"
1121
1122/**
1123 * This variable sets the input scope of the TextInput window on GDK
1124 * platforms.
1125 *
1126 * Set this hint to change the XGameUiTextEntryInputScope value that will be
1127 * passed to the window creation function. The value must be a stringified
1128 * integer, for example "0" for XGameUiTextEntryInputScope::Default.
1129 *
1130 * This hint is available only if SDL_GDK_TEXTINPUT defined.
1131 *
1132 * This hint should be set before calling SDL_StartTextInput()
1133 *
1134 * \since This hint is available since SDL 3.2.0.
1135 */
1136#define SDL_HINT_GDK_TEXTINPUT_SCOPE "SDL_GDK_TEXTINPUT_SCOPE"
1137
1138/**
1139 * This variable sets the title of the TextInput window on GDK platforms.
1140 *
1141 * This hint is available only if SDL_GDK_TEXTINPUT defined.
1142 *
1143 * This hint should be set before calling SDL_StartTextInput()
1144 *
1145 * \since This hint is available since SDL 3.2.0.
1146 */
1147#define SDL_HINT_GDK_TEXTINPUT_TITLE "SDL_GDK_TEXTINPUT_TITLE"
1148
1149/**
1150 * A variable to control whether HIDAPI uses libusb for device access.
1151 *
1152 * By default libusb will only be used for a few devices that require direct
1153 * USB access, and this can be controlled with
1154 * SDL_HINT_HIDAPI_LIBUSB_WHITELIST.
1155 *
1156 * The variable can be set to the following values:
1157 *
1158 * - "0": HIDAPI will not use libusb for device access.
1159 * - "1": HIDAPI will use libusb for device access if available. (default)
1160 *
1161 * This hint should be set before SDL is initialized.
1162 *
1163 * \since This hint is available since SDL 3.2.0.
1164 */
1165#define SDL_HINT_HIDAPI_LIBUSB "SDL_HIDAPI_LIBUSB"
1166
1167
1168/**
1169 * A variable to control whether HIDAPI uses libusb for GameCube adapters.
1170 *
1171 * The variable can be set to the following values:
1172 *
1173 * - "0": HIDAPI will not use libusb for GameCube adapters.
1174 * - "1": HIDAPI will use libusb for GameCube adapters if available. (default)
1175 *
1176 * This hint should be set before SDL is initialized.
1177 *
1178 * \since This hint is available since SDL 3.4.0.
1179 */
1180#define SDL_HINT_HIDAPI_LIBUSB_GAMECUBE "SDL_HIDAPI_LIBUSB_GAMECUBE"
1181
1182/**
1183 * A variable to control whether HIDAPI uses libusb only for whitelisted
1184 * devices.
1185 *
1186 * By default libusb will only be used for a few devices that require direct
1187 * USB access.
1188 *
1189 * The variable can be set to the following values:
1190 *
1191 * - "0": HIDAPI will use libusb for all device access.
1192 * - "1": HIDAPI will use libusb only for whitelisted devices. (default)
1193 *
1194 * This hint should be set before SDL is initialized.
1195 *
1196 * \since This hint is available since SDL 3.2.0.
1197 */
1198#define SDL_HINT_HIDAPI_LIBUSB_WHITELIST "SDL_HIDAPI_LIBUSB_WHITELIST"
1199
1200/**
1201 * A variable to control whether HIDAPI uses udev for device detection.
1202 *
1203 * The variable can be set to the following values:
1204 *
1205 * - "0": HIDAPI will poll for device changes.
1206 * - "1": HIDAPI will use udev for device detection. (default)
1207 *
1208 * This hint should be set before SDL is initialized.
1209 *
1210 * \since This hint is available since SDL 3.2.0.
1211 */
1212#define SDL_HINT_HIDAPI_UDEV "SDL_HIDAPI_UDEV"
1213
1214/**
1215 * A variable that specifies a GPU backend to use.
1216 *
1217 * By default, SDL will try all available GPU backends in a reasonable order
1218 * until it finds one that can work, but this hint allows the app or user to
1219 * force a specific target, such as "direct3d12" if, say, your hardware
1220 * supports Vulkan but you want to try using D3D12 instead.
1221 *
1222 * This hint should be set before any GPU functions are called.
1223 *
1224 * \since This hint is available since SDL 3.2.0.
1225 */
1226#define SDL_HINT_GPU_DRIVER "SDL_GPU_DRIVER"
1227
1228/**
1229 * A variable that specifies the library name to use when loading the OpenXR
1230 * loader.
1231 *
1232 * By default, SDL will try the system default name, but on some platforms
1233 * like Windows, debug builds of the OpenXR loader have a different name, and
1234 * are not always directly compatible with release applications. Setting this
1235 * hint allows you to compensate for this difference in your app when
1236 * applicable.
1237 *
1238 * This hint should be set before the OpenXR loader is loaded. For example,
1239 * creating an OpenXR GPU device will load the OpenXR loader.
1240 */
1241#define SDL_HINT_OPENXR_LIBRARY "SDL_OPENXR_LIBRARY"
1242
1243/**
1244 * A variable to control whether SDL_hid_enumerate() enumerates all HID
1245 * devices or only controllers.
1246 *
1247 * The variable can be set to the following values:
1248 *
1249 * - "0": SDL_hid_enumerate() will enumerate all HID devices.
1250 * - "1": SDL_hid_enumerate() will only enumerate controllers. (default)
1251 *
1252 * By default SDL will only enumerate controllers, to reduce risk of hanging
1253 * or crashing on devices with bad drivers and avoiding macOS keyboard capture
1254 * permission prompts.
1255 *
1256 * This hint can be set anytime.
1257 *
1258 * \since This hint is available since SDL 3.2.0.
1259 */
1260#define SDL_HINT_HIDAPI_ENUMERATE_ONLY_CONTROLLERS "SDL_HIDAPI_ENUMERATE_ONLY_CONTROLLERS"
1261
1262/**
1263 * A variable containing a list of devices to ignore in SDL_hid_enumerate().
1264 *
1265 * The format of the string is a comma separated list of USB VID/PID pairs in
1266 * hexadecimal form, e.g.
1267 *
1268 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1269 *
1270 * For example, to ignore the Shanwan DS3 controller and any Valve controller,
1271 * you might use the string "0x2563/0x0523,0x28de/0x0000"
1272 *
1273 * This hint can be set anytime.
1274 *
1275 * \since This hint is available since SDL 3.2.0.
1276 */
1277#define SDL_HINT_HIDAPI_IGNORE_DEVICES "SDL_HIDAPI_IGNORE_DEVICES"
1278
1279/**
1280 * A variable describing what IME UI elements the application can display.
1281 *
1282 * By default IME UI is handled using native components by the OS where
1283 * possible, however this can interfere with or not be visible when exclusive
1284 * fullscreen mode is used.
1285 *
1286 * The variable can be set to a comma separated list containing the following
1287 * items:
1288 *
1289 * - "none" or "0": The application can't render any IME elements, and native
1290 * UI should be used. (default)
1291 * - "composition": The application handles SDL_EVENT_TEXT_EDITING events and
1292 * can render the composition text.
1293 * - "candidates": The application handles SDL_EVENT_TEXT_EDITING_CANDIDATES
1294 * and can render the candidate list.
1295 *
1296 * This hint should be set before SDL is initialized.
1297 *
1298 * \since This hint is available since SDL 3.2.0.
1299 */
1300#define SDL_HINT_IME_IMPLEMENTED_UI "SDL_IME_IMPLEMENTED_UI"
1301
1302/**
1303 * A variable controlling whether the home indicator bar on iPhone X and later
1304 * should be hidden.
1305 *
1306 * The variable can be set to the following values:
1307 *
1308 * - "0": The indicator bar is not hidden. (default for windowed applications)
1309 * - "1": The indicator bar is hidden and is shown when the screen is touched
1310 * (useful for movie playback applications).
1311 * - "2": The indicator bar is dim and the first swipe makes it visible and
1312 * the second swipe performs the "home" action. (default for fullscreen
1313 * applications)
1314 *
1315 * This hint can be set anytime.
1316 *
1317 * \since This hint is available since SDL 3.2.0.
1318 */
1319#define SDL_HINT_IOS_HIDE_HOME_INDICATOR "SDL_IOS_HIDE_HOME_INDICATOR"
1320
1321/**
1322 * A variable that lets you enable joystick (and gamecontroller) events even
1323 * when your app is in the background.
1324 *
1325 * The variable can be set to the following values:
1326 *
1327 * - "0": Disable joystick & gamecontroller input events when the application
1328 * is in the background. (default)
1329 * - "1": Enable joystick & gamecontroller input events when the application
1330 * is in the background.
1331 *
1332 * This hint can be set anytime.
1333 *
1334 * \since This hint is available since SDL 3.2.0.
1335 */
1336#define SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS "SDL_JOYSTICK_ALLOW_BACKGROUND_EVENTS"
1337
1338/**
1339 * A variable containing a list of arcade stick style controllers.
1340 *
1341 * The format of the string is a comma separated list of USB VID/PID pairs in
1342 * hexadecimal form, e.g.
1343 *
1344 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1345 *
1346 * The variable can also take the form of "@file", in which case the named
1347 * file will be loaded and interpreted as the value of the variable.
1348 *
1349 * This hint can be set anytime.
1350 *
1351 * \since This hint is available since SDL 3.2.0.
1352 */
1353#define SDL_HINT_JOYSTICK_ARCADESTICK_DEVICES "SDL_JOYSTICK_ARCADESTICK_DEVICES"
1354
1355/**
1356 * A variable containing a list of devices that are not arcade stick style
1357 * controllers.
1358 *
1359 * This will override SDL_HINT_JOYSTICK_ARCADESTICK_DEVICES and the built in
1360 * device list.
1361 *
1362 * The format of the string is a comma separated list of USB VID/PID pairs in
1363 * hexadecimal form, e.g.
1364 *
1365 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1366 *
1367 * The variable can also take the form of "@file", in which case the named
1368 * file will be loaded and interpreted as the value of the variable.
1369 *
1370 * This hint can be set anytime.
1371 *
1372 * \since This hint is available since SDL 3.2.0.
1373 */
1374#define SDL_HINT_JOYSTICK_ARCADESTICK_DEVICES_EXCLUDED "SDL_JOYSTICK_ARCADESTICK_DEVICES_EXCLUDED"
1375
1376/**
1377 * A variable containing a list of devices that should not be considered
1378 * joysticks.
1379 *
1380 * The format of the string is a comma separated list of USB VID/PID pairs in
1381 * hexadecimal form, e.g.
1382 *
1383 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1384 *
1385 * The variable can also take the form of "@file", in which case the named
1386 * file will be loaded and interpreted as the value of the variable.
1387 *
1388 * This hint can be set anytime.
1389 *
1390 * \since This hint is available since SDL 3.2.0.
1391 */
1392#define SDL_HINT_JOYSTICK_BLACKLIST_DEVICES "SDL_JOYSTICK_BLACKLIST_DEVICES"
1393
1394/**
1395 * A variable containing a list of devices that should be considered
1396 * joysticks.
1397 *
1398 * This will override SDL_HINT_JOYSTICK_BLACKLIST_DEVICES and the built in
1399 * device list.
1400 *
1401 * The format of the string is a comma separated list of USB VID/PID pairs in
1402 * hexadecimal form, e.g.
1403 *
1404 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1405 *
1406 * The variable can also take the form of "@file", in which case the named
1407 * file will be loaded and interpreted as the value of the variable.
1408 *
1409 * This hint can be set anytime.
1410 *
1411 * \since This hint is available since SDL 3.2.0.
1412 */
1413#define SDL_HINT_JOYSTICK_BLACKLIST_DEVICES_EXCLUDED "SDL_JOYSTICK_BLACKLIST_DEVICES_EXCLUDED"
1414
1415/**
1416 * A variable containing a comma separated list of devices to open as
1417 * joysticks.
1418 *
1419 * This variable is currently only used by the Linux joystick driver.
1420 *
1421 * \since This hint is available since SDL 3.2.0.
1422 */
1423#define SDL_HINT_JOYSTICK_DEVICE "SDL_JOYSTICK_DEVICE"
1424
1425/**
1426 * A variable containing a list of drum style controllers.
1427 *
1428 * The format of the string is a comma separated list of USB VID/PID pairs in
1429 * hexadecimal form, e.g.
1430 *
1431 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1432 *
1433 * The variable can also take the form of "@file", in which case the named
1434 * file will be loaded and interpreted as the value of the variable.
1435 *
1436 * This hint can be set anytime.
1437 *
1438 * \since This hint is available since SDL 3.4.4.
1439 */
1440#define SDL_HINT_JOYSTICK_DRUM_DEVICES "SDL_JOYSTICK_DRUM_DEVICES"
1441
1442/**
1443 * A variable controlling whether enhanced reports should be used for
1444 * controllers when using the HIDAPI driver.
1445 *
1446 * Enhanced reports allow rumble and effects on Bluetooth PlayStation
1447 * controllers and gyro on Nintendo Switch controllers, but break Windows
1448 * DirectInput for other applications that don't use SDL.
1449 *
1450 * Once enhanced reports are enabled, they can't be disabled on PlayStation
1451 * controllers without power cycling the controller.
1452 *
1453 * The variable can be set to the following values:
1454 *
1455 * - "0": enhanced reports are not enabled.
1456 * - "1": enhanced reports are enabled. (default)
1457 * - "auto": enhanced features are advertised to the application, but SDL
1458 * doesn't change the controller report mode unless the application uses
1459 * them.
1460 *
1461 * This hint can be enabled anytime.
1462 *
1463 * \since This hint is available since SDL 3.2.0.
1464 */
1465#define SDL_HINT_JOYSTICK_ENHANCED_REPORTS "SDL_JOYSTICK_ENHANCED_REPORTS"
1466
1467/**
1468 * A variable containing a list of flightstick style controllers.
1469 *
1470 * The format of the string is a comma separated list of USB VID/PID pairs in
1471 * hexadecimal form, e.g.
1472 *
1473 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1474 *
1475 * The variable can also take the form of @file, in which case the named file
1476 * will be loaded and interpreted as the value of the variable.
1477 *
1478 * This hint can be set anytime.
1479 *
1480 * \since This hint is available since SDL 3.2.0.
1481 */
1482#define SDL_HINT_JOYSTICK_FLIGHTSTICK_DEVICES "SDL_JOYSTICK_FLIGHTSTICK_DEVICES"
1483
1484/**
1485 * A variable containing a list of devices that are not flightstick style
1486 * controllers.
1487 *
1488 * This will override SDL_HINT_JOYSTICK_FLIGHTSTICK_DEVICES and the built in
1489 * device list.
1490 *
1491 * The format of the string is a comma separated list of USB VID/PID pairs in
1492 * hexadecimal form, e.g.
1493 *
1494 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1495 *
1496 * The variable can also take the form of "@file", in which case the named
1497 * file will be loaded and interpreted as the value of the variable.
1498 *
1499 * This hint can be set anytime.
1500 *
1501 * \since This hint is available since SDL 3.2.0.
1502 */
1503#define SDL_HINT_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED "SDL_JOYSTICK_FLIGHTSTICK_DEVICES_EXCLUDED"
1504
1505/**
1506 * A variable controlling whether GameInput should be used for controller
1507 * handling on Windows.
1508 *
1509 * The variable can be set to the following values:
1510 *
1511 * - "0": GameInput is not used.
1512 * - "1": GameInput is used.
1513 *
1514 * The default is "1" on GDK platforms, and "0" otherwise.
1515 *
1516 * This hint should be set before SDL is initialized.
1517 *
1518 * \since This hint is available since SDL 3.2.0.
1519 */
1520#define SDL_HINT_JOYSTICK_GAMEINPUT "SDL_JOYSTICK_GAMEINPUT"
1521
1522/**
1523 * A variable controlling whether GameInput should be used for handling GIP
1524 * devices that require raw report processing, but aren't supported by HIDRAW,
1525 * such as Xbox One Guitars.
1526 *
1527 * Note that this is only supported with GameInput 3 or newer.
1528 *
1529 * The variable can be set to the following values:
1530 *
1531 * - "0": GameInput is not used to handle raw GIP devices.
1532 * - "1": GameInput is used.
1533 *
1534 * The default is "1" when using GameInput 3 or newer, and is "0" otherwise.
1535 *
1536 * This hint should be set before SDL is initialized.
1537 *
1538 * \since This hint is available since SDL 3.4.4.
1539 */
1540#define SDL_HINT_JOYSTICK_GAMEINPUT_RAW "SDL_JOYSTICK_GAMEINPUT_RAW"
1541
1542/**
1543 * A variable containing a list of devices known to have a GameCube form
1544 * factor.
1545 *
1546 * The format of the string is a comma separated list of USB VID/PID pairs in
1547 * hexadecimal form, e.g.
1548 *
1549 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1550 *
1551 * The variable can also take the form of "@file", in which case the named
1552 * file will be loaded and interpreted as the value of the variable.
1553 *
1554 * This hint can be set anytime.
1555 *
1556 * \since This hint is available since SDL 3.2.0.
1557 */
1558#define SDL_HINT_JOYSTICK_GAMECUBE_DEVICES "SDL_JOYSTICK_GAMECUBE_DEVICES"
1559
1560/**
1561 * A variable containing a list of devices known not to have a GameCube form
1562 * factor.
1563 *
1564 * This will override SDL_HINT_JOYSTICK_GAMECUBE_DEVICES and the built in
1565 * device list.
1566 *
1567 * The format of the string is a comma separated list of USB VID/PID pairs in
1568 * hexadecimal form, e.g.
1569 *
1570 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1571 *
1572 * The variable can also take the form of "@file", in which case the named
1573 * file will be loaded and interpreted as the value of the variable.
1574 *
1575 * This hint can be set anytime.
1576 *
1577 * \since This hint is available since SDL 3.2.0.
1578 */
1579#define SDL_HINT_JOYSTICK_GAMECUBE_DEVICES_EXCLUDED "SDL_JOYSTICK_GAMECUBE_DEVICES_EXCLUDED"
1580
1581/**
1582 * A variable containing a list of guitar style controllers.
1583 *
1584 * The format of the string is a comma separated list of USB VID/PID pairs in
1585 * hexadecimal form, e.g.
1586 *
1587 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
1588 *
1589 * The variable can also take the form of "@file", in which case the named
1590 * file will be loaded and interpreted as the value of the variable.
1591 *
1592 * This hint can be set anytime.
1593 *
1594 * \since This hint is available since SDL 3.4.4.
1595 */
1596#define SDL_HINT_JOYSTICK_GUITAR_DEVICES "SDL_JOYSTICK_GUITAR_DEVICES"
1597
1598/**
1599 * A variable controlling whether the HIDAPI joystick drivers should be used.
1600 *
1601 * The variable can be set to the following values:
1602 *
1603 * - "0": HIDAPI drivers are not used.
1604 * - "1": HIDAPI drivers are used. (default)
1605 *
1606 * This variable is the default for all drivers, but can be overridden by the
1607 * hints for specific drivers below.
1608 *
1609 * This hint should be set before initializing joysticks and gamepads.
1610 *
1611 * \since This hint is available since SDL 3.2.0.
1612 */
1613#define SDL_HINT_JOYSTICK_HIDAPI "SDL_JOYSTICK_HIDAPI"
1614
1615/**
1616 * A variable controlling whether Nintendo Switch Joy-Con controllers will be
1617 * combined into a single Pro-like controller when using the HIDAPI driver.
1618 *
1619 * The variable can be set to the following values:
1620 *
1621 * - "0": Left and right Joy-Con controllers will not be combined and each
1622 * will be a mini-gamepad.
1623 * - "1": Left and right Joy-Con controllers will be combined into a single
1624 * controller. (default)
1625 *
1626 * This hint should be set before initializing joysticks and gamepads.
1627 *
1628 * \since This hint is available since SDL 3.2.0.
1629 */
1630#define SDL_HINT_JOYSTICK_HIDAPI_COMBINE_JOY_CONS "SDL_JOYSTICK_HIDAPI_COMBINE_JOY_CONS"
1631
1632/**
1633 * A variable controlling whether the HIDAPI driver for Nintendo GameCube
1634 * controllers should be used.
1635 *
1636 * The variable can be set to the following values:
1637 *
1638 * - "0": HIDAPI driver is not used.
1639 * - "1": HIDAPI driver is used.
1640 *
1641 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI
1642 *
1643 * This hint should be set before initializing joysticks and gamepads.
1644 *
1645 * \since This hint is available since SDL 3.2.0.
1646 */
1647#define SDL_HINT_JOYSTICK_HIDAPI_GAMECUBE "SDL_JOYSTICK_HIDAPI_GAMECUBE"
1648
1649/**
1650 * A variable controlling whether rumble is used to implement the GameCube
1651 * controller's 3 rumble modes, Stop(0), Rumble(1), and StopHard(2).
1652 *
1653 * This is useful for applications that need full compatibility for things
1654 * like ADSR envelopes. - Stop is implemented by setting low_frequency_rumble
1655 * to 0 and high_frequency_rumble >0 - Rumble is both at any arbitrary value -
1656 * StopHard is implemented by setting both low_frequency_rumble and
1657 * high_frequency_rumble to 0
1658 *
1659 * The variable can be set to the following values:
1660 *
1661 * - "0": Normal rumble behavior is behavior is used. (default)
1662 * - "1": Proper GameCube controller rumble behavior is used.
1663 *
1664 * This hint can be set anytime.
1665 *
1666 * \since This hint is available since SDL 3.2.0.
1667 */
1668#define SDL_HINT_JOYSTICK_HIDAPI_GAMECUBE_RUMBLE_BRAKE "SDL_JOYSTICK_HIDAPI_GAMECUBE_RUMBLE_BRAKE"
1669
1670/**
1671 * A variable controlling whether the HIDAPI driver for Nintendo Switch
1672 * Joy-Cons should be used.
1673 *
1674 * The variable can be set to the following values:
1675 *
1676 * - "0": HIDAPI driver is not used.
1677 * - "1": HIDAPI driver is used.
1678 *
1679 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1680 *
1681 * This hint should be set before initializing joysticks and gamepads.
1682 *
1683 * \since This hint is available since SDL 3.2.0.
1684 */
1685#define SDL_HINT_JOYSTICK_HIDAPI_JOY_CONS "SDL_JOYSTICK_HIDAPI_JOY_CONS"
1686
1687/**
1688 * A variable controlling whether the Home button LED should be turned on when
1689 * a Nintendo Switch Joy-Con controller is opened.
1690 *
1691 * The variable can be set to the following values:
1692 *
1693 * - "0": home button LED is turned off
1694 * - "1": home button LED is turned on
1695 *
1696 * By default the Home button LED state is not changed. This hint can also be
1697 * set to a floating point value between 0.0 and 1.0 which controls the
1698 * brightness of the Home button LED.
1699 *
1700 * This hint can be set anytime.
1701 *
1702 * \since This hint is available since SDL 3.2.0.
1703 */
1704#define SDL_HINT_JOYSTICK_HIDAPI_JOYCON_HOME_LED "SDL_JOYSTICK_HIDAPI_JOYCON_HOME_LED"
1705
1706/**
1707 * A variable controlling whether the HIDAPI driver for Amazon Luna
1708 * controllers connected via Bluetooth should be used.
1709 *
1710 * The variable can be set to the following values:
1711 *
1712 * - "0": HIDAPI driver is not used.
1713 * - "1": HIDAPI driver is used.
1714 *
1715 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1716 *
1717 * This hint should be set before initializing joysticks and gamepads.
1718 *
1719 * \since This hint is available since SDL 3.2.0.
1720 */
1721#define SDL_HINT_JOYSTICK_HIDAPI_LUNA "SDL_JOYSTICK_HIDAPI_LUNA"
1722
1723/**
1724 * A variable controlling whether the HIDAPI driver for Nintendo Online
1725 * classic controllers should be used.
1726 *
1727 * The variable can be set to the following values:
1728 *
1729 * - "0": HIDAPI driver is not used.
1730 * - "1": HIDAPI driver is used.
1731 *
1732 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1733 *
1734 * This hint should be set before initializing joysticks and gamepads.
1735 *
1736 * \since This hint is available since SDL 3.2.0.
1737 */
1738#define SDL_HINT_JOYSTICK_HIDAPI_NINTENDO_CLASSIC "SDL_JOYSTICK_HIDAPI_NINTENDO_CLASSIC"
1739
1740/**
1741 * A variable controlling whether the HIDAPI driver for PS3 controllers should
1742 * be used.
1743 *
1744 * The variable can be set to the following values:
1745 *
1746 * - "0": HIDAPI driver is not used.
1747 * - "1": HIDAPI driver is used.
1748 *
1749 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI on macOS, and "0" on
1750 * other platforms.
1751 *
1752 * For official Sony driver (sixaxis.sys) use
1753 * SDL_HINT_JOYSTICK_HIDAPI_PS3_SIXAXIS_DRIVER. See
1754 * https://github.com/ViGEm/DsHidMini for an alternative driver on Windows.
1755 *
1756 * This hint should be set before initializing joysticks and gamepads.
1757 *
1758 * \since This hint is available since SDL 3.2.0.
1759 */
1760#define SDL_HINT_JOYSTICK_HIDAPI_PS3 "SDL_JOYSTICK_HIDAPI_PS3"
1761
1762/**
1763 * A variable controlling whether the Sony driver (sixaxis.sys) for PS3
1764 * controllers (Sixaxis/DualShock 3) should be used.
1765 *
1766 * The variable can be set to the following values:
1767 *
1768 * - "0": Sony driver (sixaxis.sys) is not used.
1769 * - "1": Sony driver (sixaxis.sys) is used.
1770 *
1771 * The default value is 0.
1772 *
1773 * This hint should be set before initializing joysticks and gamepads.
1774 *
1775 * \since This hint is available since SDL 3.2.0.
1776 */
1777#define SDL_HINT_JOYSTICK_HIDAPI_PS3_SIXAXIS_DRIVER "SDL_JOYSTICK_HIDAPI_PS3_SIXAXIS_DRIVER"
1778
1779/**
1780 * A variable controlling whether the HIDAPI driver for PS4 controllers should
1781 * be used.
1782 *
1783 * The variable can be set to the following values:
1784 *
1785 * - "0": HIDAPI driver is not used.
1786 * - "1": HIDAPI driver is used.
1787 *
1788 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1789 *
1790 * This hint should be set before initializing joysticks and gamepads.
1791 *
1792 * \since This hint is available since SDL 3.2.0.
1793 */
1794#define SDL_HINT_JOYSTICK_HIDAPI_PS4 "SDL_JOYSTICK_HIDAPI_PS4"
1795
1796/**
1797 * A variable controlling the update rate of the PS4 controller over Bluetooth
1798 * when using the HIDAPI driver.
1799 *
1800 * This defaults to 4 ms, to match the behavior over USB, and to be more
1801 * friendly to other Bluetooth devices and older Bluetooth hardware on the
1802 * computer. It can be set to "1" (1000Hz), "2" (500Hz) and "4" (250Hz)
1803 *
1804 * This hint can be set anytime, but only takes effect when extended input
1805 * reports are enabled.
1806 *
1807 * \since This hint is available since SDL 3.2.0.
1808 */
1809#define SDL_HINT_JOYSTICK_HIDAPI_PS4_REPORT_INTERVAL "SDL_JOYSTICK_HIDAPI_PS4_REPORT_INTERVAL"
1810
1811/**
1812 * A variable controlling whether the HIDAPI driver for PS5 controllers should
1813 * be used.
1814 *
1815 * The variable can be set to the following values:
1816 *
1817 * - "0": HIDAPI driver is not used.
1818 * - "1": HIDAPI driver is used.
1819 *
1820 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1821 *
1822 * This hint should be set before initializing joysticks and gamepads.
1823 *
1824 * \since This hint is available since SDL 3.2.0.
1825 */
1826#define SDL_HINT_JOYSTICK_HIDAPI_PS5 "SDL_JOYSTICK_HIDAPI_PS5"
1827
1828/**
1829 * A variable controlling whether the player LEDs should be lit to indicate
1830 * which player is associated with a PS5 controller.
1831 *
1832 * The variable can be set to the following values:
1833 *
1834 * - "0": player LEDs are not enabled.
1835 * - "1": player LEDs are enabled. (default)
1836 *
1837 * \since This hint is available since SDL 3.2.0.
1838 */
1839#define SDL_HINT_JOYSTICK_HIDAPI_PS5_PLAYER_LED "SDL_JOYSTICK_HIDAPI_PS5_PLAYER_LED"
1840
1841/**
1842 * A variable controlling whether the HIDAPI driver for NVIDIA SHIELD
1843 * controllers should be used.
1844 *
1845 * The variable can be set to the following values:
1846 *
1847 * - "0": HIDAPI driver is not used.
1848 * - "1": HIDAPI driver is used.
1849 *
1850 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1851 *
1852 * This hint should be set before initializing joysticks and gamepads.
1853 *
1854 * \since This hint is available since SDL 3.2.0.
1855 */
1856#define SDL_HINT_JOYSTICK_HIDAPI_SHIELD "SDL_JOYSTICK_HIDAPI_SHIELD"
1857
1858/**
1859 * A variable controlling whether the HIDAPI driver for Google Stadia
1860 * controllers should be used.
1861 *
1862 * The variable can be set to the following values:
1863 *
1864 * - "0": HIDAPI driver is not used.
1865 * - "1": HIDAPI driver is used.
1866 *
1867 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1868 *
1869 * \since This hint is available since SDL 3.2.0.
1870 */
1871#define SDL_HINT_JOYSTICK_HIDAPI_STADIA "SDL_JOYSTICK_HIDAPI_STADIA"
1872
1873/**
1874 * A variable controlling whether the HIDAPI driver for Bluetooth Steam
1875 * Controllers should be used.
1876 *
1877 * The variable can be set to the following values:
1878 *
1879 * - "0": HIDAPI driver is not used. (default)
1880 * - "1": HIDAPI driver is used for Steam Controllers, which requires
1881 * Bluetooth access and may prompt the user for permission on iOS and
1882 * Android.
1883 *
1884 * This hint should be set before initializing joysticks and gamepads.
1885 *
1886 * \since This hint is available since SDL 3.2.0.
1887 */
1888#define SDL_HINT_JOYSTICK_HIDAPI_STEAM "SDL_JOYSTICK_HIDAPI_STEAM"
1889
1890/**
1891 * A variable controlling whether the Steam button LED should be turned on
1892 * when a Steam controller is opened.
1893 *
1894 * The variable can be set to the following values:
1895 *
1896 * - "0": Steam button LED is turned off.
1897 * - "1": Steam button LED is turned on.
1898 *
1899 * By default the Steam button LED state is not changed. This hint can also be
1900 * set to a floating point value between 0.0 and 1.0 which controls the
1901 * brightness of the Steam button LED.
1902 *
1903 * This hint can be set anytime.
1904 *
1905 * \since This hint is available since SDL 3.2.0.
1906 */
1907#define SDL_HINT_JOYSTICK_HIDAPI_STEAM_HOME_LED "SDL_JOYSTICK_HIDAPI_STEAM_HOME_LED"
1908
1909/**
1910 * A variable controlling whether the HIDAPI driver for the Steam Deck builtin
1911 * controller should be used.
1912 *
1913 * The variable can be set to the following values:
1914 *
1915 * - "0": HIDAPI driver is not used.
1916 * - "1": HIDAPI driver is used.
1917 *
1918 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1919 *
1920 * This hint should be set before initializing joysticks and gamepads.
1921 *
1922 * \since This hint is available since SDL 3.2.0.
1923 */
1924#define SDL_HINT_JOYSTICK_HIDAPI_STEAMDECK "SDL_JOYSTICK_HIDAPI_STEAMDECK"
1925
1926/**
1927 * A variable controlling whether the HIDAPI driver for HORI licensed Steam
1928 * controllers should be used.
1929 *
1930 * The variable can be set to the following values:
1931 *
1932 * - "0": HIDAPI driver is not used.
1933 * - "1": HIDAPI driver is used.
1934 *
1935 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1936 *
1937 * This hint should be set before initializing joysticks and gamepads.
1938 *
1939 * \since This hint is available since SDL 3.2.0.
1940 */
1941#define SDL_HINT_JOYSTICK_HIDAPI_STEAM_HORI "SDL_JOYSTICK_HIDAPI_STEAM_HORI"
1942
1943/**
1944 * A variable controlling whether the HIDAPI driver for some Logitech wheels
1945 * should be used.
1946 *
1947 * The variable can be set to the following values:
1948 *
1949 * - "0": HIDAPI driver is not used.
1950 * - "1": HIDAPI driver is used.
1951 *
1952 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1953 *
1954 * This hint should be set before initializing joysticks and gamepads.
1955 *
1956 * \since This hint is available since SDL 3.4.0.
1957 */
1958#define SDL_HINT_JOYSTICK_HIDAPI_LG4FF "SDL_JOYSTICK_HIDAPI_LG4FF"
1959
1960/**
1961 * A variable controlling whether the HIDAPI driver for 8BitDo controllers
1962 * should be used.
1963 *
1964 * The variable can be set to the following values:
1965 *
1966 * - "0": HIDAPI driver is not used.
1967 * - "1": HIDAPI driver is used.
1968 *
1969 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1970 *
1971 * This hint should be set before initializing joysticks and gamepads.
1972 *
1973 * \since This hint is available since SDL 3.4.0.
1974 */
1975#define SDL_HINT_JOYSTICK_HIDAPI_8BITDO "SDL_JOYSTICK_HIDAPI_8BITDO"
1976
1977/**
1978 * A variable controlling whether the HIDAPI driver for SInput controllers
1979 * should be used.
1980 *
1981 * More info - https://github.com/HandHeldLegend/SInput-HID
1982 *
1983 * The variable can be set to the following values:
1984 *
1985 * - "0": HIDAPI driver is not used.
1986 * - "1": HIDAPI driver is used.
1987 *
1988 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
1989 *
1990 * This hint should be set before initializing joysticks and gamepads.
1991 *
1992 * \since This hint is available since SDL 3.4.0.
1993 */
1994#define SDL_HINT_JOYSTICK_HIDAPI_SINPUT "SDL_JOYSTICK_HIDAPI_SINPUT"
1995
1996/**
1997 * A variable controlling whether the HIDAPI driver for ZUIKI controllers
1998 * should be used.
1999 *
2000 * The variable can be set to the following values:
2001 *
2002 * - "0": HIDAPI driver is not used.
2003 * - "1": HIDAPI driver is used.
2004 *
2005 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
2006 *
2007 * This hint should be set before initializing joysticks and gamepads.
2008 *
2009 * \since This hint is available since SDL 3.4.0.
2010 */
2011#define SDL_HINT_JOYSTICK_HIDAPI_ZUIKI "SDL_JOYSTICK_HIDAPI_ZUIKI"
2012
2013/**
2014 * A variable controlling whether the HIDAPI driver for Flydigi controllers
2015 * should be used.
2016 *
2017 * The variable can be set to the following values:
2018 *
2019 * - "0": HIDAPI driver is not used.
2020 * - "1": HIDAPI driver is used.
2021 *
2022 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
2023 *
2024 * This hint should be set before initializing joysticks and gamepads.
2025 *
2026 * \since This hint is available since SDL 3.4.0.
2027 */
2028#define SDL_HINT_JOYSTICK_HIDAPI_FLYDIGI "SDL_JOYSTICK_HIDAPI_FLYDIGI"
2029
2030/**
2031 * A variable controlling whether the HIDAPI driver for GameSir controllers
2032 * should be used.
2033 *
2034 * The variable can be set to the following values:
2035 *
2036 * - "0": HIDAPI driver is not used.
2037 * - "1": HIDAPI driver is used.
2038 *
2039 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
2040 *
2041 * This hint should be set before initializing joysticks and gamepads.
2042 *
2043 * \since This hint is available since SDL 3.5.0.
2044 */
2045#define SDL_HINT_JOYSTICK_HIDAPI_GAMESIR "SDL_JOYSTICK_HIDAPI_GAMESIR"
2046
2047/**
2048 * A variable controlling whether the HIDAPI driver for Nintendo Switch
2049 * controllers should be used.
2050 *
2051 * The variable can be set to the following values:
2052 *
2053 * - "0": HIDAPI driver is not used.
2054 * - "1": HIDAPI driver is used.
2055 *
2056 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
2057 *
2058 * This hint should be set before initializing joysticks and gamepads.
2059 *
2060 * \since This hint is available since SDL 3.2.0.
2061 */
2062#define SDL_HINT_JOYSTICK_HIDAPI_SWITCH "SDL_JOYSTICK_HIDAPI_SWITCH"
2063
2064/**
2065 * A variable controlling whether the Home button LED should be turned on when
2066 * a Nintendo Switch Pro controller is opened.
2067 *
2068 * The variable can be set to the following values:
2069 *
2070 * - "0": Home button LED is turned off.
2071 * - "1": Home button LED is turned on.
2072 *
2073 * By default the Home button LED state is not changed. This hint can also be
2074 * set to a floating point value between 0.0 and 1.0 which controls the
2075 * brightness of the Home button LED.
2076 *
2077 * This hint can be set anytime.
2078 *
2079 * \since This hint is available since SDL 3.2.0.
2080 */
2081#define SDL_HINT_JOYSTICK_HIDAPI_SWITCH_HOME_LED "SDL_JOYSTICK_HIDAPI_SWITCH_HOME_LED"
2082
2083/**
2084 * A variable controlling whether the player LEDs should be lit to indicate
2085 * which player is associated with a Nintendo Switch controller.
2086 *
2087 * The variable can be set to the following values:
2088 *
2089 * - "0": Player LEDs are not enabled.
2090 * - "1": Player LEDs are enabled. (default)
2091 *
2092 * This hint can be set anytime.
2093 *
2094 * \since This hint is available since SDL 3.2.0.
2095 */
2096#define SDL_HINT_JOYSTICK_HIDAPI_SWITCH_PLAYER_LED "SDL_JOYSTICK_HIDAPI_SWITCH_PLAYER_LED"
2097
2098/**
2099 * A variable controlling whether the HIDAPI driver for Nintendo Switch 2
2100 * controllers should be used.
2101 *
2102 * The variable can be set to the following values:
2103 *
2104 * - "0": HIDAPI driver is not used.
2105 * - "1": HIDAPI driver is used.
2106 *
2107 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI.
2108 *
2109 * This hint should be set before initializing joysticks and gamepads.
2110 *
2111 * \since This hint is available since SDL 3.4.0.
2112 */
2113#define SDL_HINT_JOYSTICK_HIDAPI_SWITCH2 "SDL_JOYSTICK_HIDAPI_SWITCH2"
2114
2115/**
2116 * A variable controlling whether Nintendo Switch Joy-Con controllers will be
2117 * in vertical mode when using the HIDAPI driver.
2118 *
2119 * The variable can be set to the following values:
2120 *
2121 * - "0": Left and right Joy-Con controllers will not be in vertical mode.
2122 * (default)
2123 * - "1": Left and right Joy-Con controllers will be in vertical mode.
2124 *
2125 * This hint should be set before opening a Joy-Con controller.
2126 *
2127 * \since This hint is available since SDL 3.2.0.
2128 */
2129#define SDL_HINT_JOYSTICK_HIDAPI_VERTICAL_JOY_CONS "SDL_JOYSTICK_HIDAPI_VERTICAL_JOY_CONS"
2130
2131/**
2132 * A variable controlling whether the HIDAPI driver for Nintendo Wii and Wii U
2133 * controllers should be used.
2134 *
2135 * The variable can be set to the following values:
2136 *
2137 * - "0": HIDAPI driver is not used.
2138 * - "1": HIDAPI driver is used.
2139 *
2140 * This driver doesn't work with the dolphinbar, so the default is false for
2141 * now.
2142 *
2143 * This hint should be set before initializing joysticks and gamepads.
2144 *
2145 * \since This hint is available since SDL 3.2.0.
2146 */
2147#define SDL_HINT_JOYSTICK_HIDAPI_WII "SDL_JOYSTICK_HIDAPI_WII"
2148
2149/**
2150 * A variable controlling whether the player LEDs should be lit to indicate
2151 * which player is associated with a Wii controller.
2152 *
2153 * The variable can be set to the following values:
2154 *
2155 * - "0": Player LEDs are not enabled.
2156 * - "1": Player LEDs are enabled. (default)
2157 *
2158 * This hint can be set anytime.
2159 *
2160 * \since This hint is available since SDL 3.2.0.
2161 */
2162#define SDL_HINT_JOYSTICK_HIDAPI_WII_PLAYER_LED "SDL_JOYSTICK_HIDAPI_WII_PLAYER_LED"
2163
2164/**
2165 * A variable controlling whether the HIDAPI driver for XBox controllers
2166 * should be used.
2167 *
2168 * The variable can be set to the following values:
2169 *
2170 * - "0": HIDAPI driver is not used.
2171 * - "1": HIDAPI driver is used.
2172 *
2173 * The default is "0" on Windows, otherwise the value of
2174 * SDL_HINT_JOYSTICK_HIDAPI
2175 *
2176 * This hint should be set before initializing joysticks and gamepads.
2177 *
2178 * \since This hint is available since SDL 3.2.0.
2179 */
2180#define SDL_HINT_JOYSTICK_HIDAPI_XBOX "SDL_JOYSTICK_HIDAPI_XBOX"
2181
2182/**
2183 * A variable controlling whether the HIDAPI driver for XBox 360 controllers
2184 * should be used.
2185 *
2186 * The variable can be set to the following values:
2187 *
2188 * - "0": HIDAPI driver is not used.
2189 * - "1": HIDAPI driver is used.
2190 *
2191 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI_XBOX
2192 *
2193 * This hint should be set before initializing joysticks and gamepads.
2194 *
2195 * \since This hint is available since SDL 3.2.0.
2196 */
2197#define SDL_HINT_JOYSTICK_HIDAPI_XBOX_360 "SDL_JOYSTICK_HIDAPI_XBOX_360"
2198
2199/**
2200 * A variable controlling whether the player LEDs should be lit to indicate
2201 * which player is associated with an Xbox 360 controller.
2202 *
2203 * The variable can be set to the following values:
2204 *
2205 * - "0": Player LEDs are not enabled.
2206 * - "1": Player LEDs are enabled. (default)
2207 *
2208 * This hint can be set anytime.
2209 *
2210 * \since This hint is available since SDL 3.2.0.
2211 */
2212#define SDL_HINT_JOYSTICK_HIDAPI_XBOX_360_PLAYER_LED "SDL_JOYSTICK_HIDAPI_XBOX_360_PLAYER_LED"
2213
2214/**
2215 * A variable controlling whether the HIDAPI driver for XBox 360 wireless
2216 * controllers should be used.
2217 *
2218 * The variable can be set to the following values:
2219 *
2220 * - "0": HIDAPI driver is not used.
2221 * - "1": HIDAPI driver is used.
2222 *
2223 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI_XBOX_360
2224 *
2225 * This hint should be set before initializing joysticks and gamepads.
2226 *
2227 * \since This hint is available since SDL 3.2.0.
2228 */
2229#define SDL_HINT_JOYSTICK_HIDAPI_XBOX_360_WIRELESS "SDL_JOYSTICK_HIDAPI_XBOX_360_WIRELESS"
2230
2231/**
2232 * A variable controlling whether the HIDAPI driver for XBox One controllers
2233 * should be used.
2234 *
2235 * The variable can be set to the following values:
2236 *
2237 * - "0": HIDAPI driver is not used.
2238 * - "1": HIDAPI driver is used.
2239 *
2240 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI_XBOX.
2241 *
2242 * This hint should be set before initializing joysticks and gamepads.
2243 *
2244 * \since This hint is available since SDL 3.2.0.
2245 */
2246#define SDL_HINT_JOYSTICK_HIDAPI_XBOX_ONE "SDL_JOYSTICK_HIDAPI_XBOX_ONE"
2247
2248/**
2249 * A variable controlling whether the Home button LED should be turned on when
2250 * an Xbox One controller is opened.
2251 *
2252 * The variable can be set to the following values:
2253 *
2254 * - "0": Home button LED is turned off.
2255 * - "1": Home button LED is turned on.
2256 *
2257 * By default the Home button LED state is not changed. This hint can also be
2258 * set to a floating point value between 0.0 and 1.0 which controls the
2259 * brightness of the Home button LED. The default brightness is 0.4.
2260 *
2261 * This hint can be set anytime.
2262 *
2263 * \since This hint is available since SDL 3.2.0.
2264 */
2265#define SDL_HINT_JOYSTICK_HIDAPI_XBOX_ONE_HOME_LED "SDL_JOYSTICK_HIDAPI_XBOX_ONE_HOME_LED"
2266
2267/**
2268 * A variable controlling whether the new HIDAPI driver for wired Xbox One
2269 * (GIP) controllers should be used.
2270 *
2271 * The variable can be set to the following values:
2272 *
2273 * - "0": HIDAPI driver is not used.
2274 * - "1": HIDAPI driver is used.
2275 *
2276 * The default is the value of SDL_HINT_JOYSTICK_HIDAPI_XBOX_ONE.
2277 *
2278 * This hint should be set before initializing joysticks and gamepads.
2279 *
2280 * \since This hint is available since SDL 3.4.0.
2281 */
2282#define SDL_HINT_JOYSTICK_HIDAPI_GIP "SDL_JOYSTICK_HIDAPI_GIP"
2283
2284/**
2285 * A variable controlling whether the new HIDAPI driver for wired Xbox One
2286 * (GIP) controllers should reset the controller if it can't get the metadata
2287 * from the controller.
2288 *
2289 * The variable can be set to the following values:
2290 *
2291 * - "0": Assume this is a generic controller.
2292 * - "1": Reset the controller to get metadata.
2293 *
2294 * By default the controller is reset. This is so we can properly detect the
2295 * controller type.
2296 *
2297 * This hint should be set before initializing joysticks and gamepads.
2298 *
2299 * \since This hint is available since SDL 3.4.0.
2300 */
2301#define SDL_HINT_JOYSTICK_HIDAPI_GIP_RESET_FOR_METADATA "SDL_JOYSTICK_HIDAPI_GIP_RESET_FOR_METADATA"
2302
2303/**
2304 * A variable controlling whether IOKit should be used for controller
2305 * handling.
2306 *
2307 * The variable can be set to the following values:
2308 *
2309 * - "0": IOKit is not used.
2310 * - "1": IOKit is used. (default)
2311 *
2312 * This hint should be set before SDL is initialized.
2313 *
2314 * \since This hint is available since SDL 3.2.0.
2315 */
2316#define SDL_HINT_JOYSTICK_IOKIT "SDL_JOYSTICK_IOKIT"
2317
2318/**
2319 * A variable controlling whether to use the classic /dev/input/js* joystick
2320 * interface or the newer /dev/input/event* joystick interface on Linux.
2321 *
2322 * The variable can be set to the following values:
2323 *
2324 * - "0": Use /dev/input/event* (default)
2325 * - "1": Use /dev/input/js*
2326 *
2327 * This hint should be set before SDL is initialized.
2328 *
2329 * \since This hint is available since SDL 3.2.0.
2330 */
2331#define SDL_HINT_JOYSTICK_LINUX_CLASSIC "SDL_JOYSTICK_LINUX_CLASSIC"
2332
2333/**
2334 * A variable controlling whether joysticks on Linux adhere to their
2335 * HID-defined deadzones or return unfiltered values.
2336 *
2337 * The variable can be set to the following values:
2338 *
2339 * - "0": Return unfiltered joystick axis values. (default)
2340 * - "1": Return axis values with deadzones taken into account.
2341 *
2342 * This hint should be set before a controller is opened.
2343 *
2344 * \since This hint is available since SDL 3.2.0.
2345 */
2346#define SDL_HINT_JOYSTICK_LINUX_DEADZONES "SDL_JOYSTICK_LINUX_DEADZONES"
2347
2348/**
2349 * A variable controlling whether joysticks on Linux will always treat 'hat'
2350 * axis inputs (ABS_HAT0X - ABS_HAT3Y) as 8-way digital hats without checking
2351 * whether they may be analog.
2352 *
2353 * The variable can be set to the following values:
2354 *
2355 * - "0": Only map hat axis inputs to digital hat outputs if the input axes
2356 * appear to actually be digital. (default)
2357 * - "1": Always handle the input axes numbered ABS_HAT0X to ABS_HAT3Y as
2358 * digital hats.
2359 *
2360 * This hint should be set before a controller is opened.
2361 *
2362 * \since This hint is available since SDL 3.2.0.
2363 */
2364#define SDL_HINT_JOYSTICK_LINUX_DIGITAL_HATS "SDL_JOYSTICK_LINUX_DIGITAL_HATS"
2365
2366/**
2367 * A variable controlling whether digital hats on Linux will apply deadzones
2368 * to their underlying input axes or use unfiltered values.
2369 *
2370 * The variable can be set to the following values:
2371 *
2372 * - "0": Return digital hat values based on unfiltered input axis values.
2373 * - "1": Return digital hat values with deadzones on the input axes taken
2374 * into account. (default)
2375 *
2376 * This hint should be set before a controller is opened.
2377 *
2378 * \since This hint is available since SDL 3.2.0.
2379 */
2380#define SDL_HINT_JOYSTICK_LINUX_HAT_DEADZONES "SDL_JOYSTICK_LINUX_HAT_DEADZONES"
2381
2382/**
2383 * A variable controlling whether GCController should be used for controller
2384 * handling.
2385 *
2386 * The variable can be set to the following values:
2387 *
2388 * - "0": GCController is not used.
2389 * - "1": GCController is used. (default)
2390 *
2391 * This hint should be set before SDL is initialized.
2392 *
2393 * \since This hint is available since SDL 3.2.0.
2394 */
2395#define SDL_HINT_JOYSTICK_MFI "SDL_JOYSTICK_MFI"
2396
2397/**
2398 * A variable controlling whether the RAWINPUT joystick drivers should be used
2399 * for better handling XInput-capable devices.
2400 *
2401 * The variable can be set to the following values:
2402 *
2403 * - "0": RAWINPUT drivers are not used. (default)
2404 * - "1": RAWINPUT drivers are used.
2405 *
2406 * This hint should be set before SDL is initialized.
2407 *
2408 * \since This hint is available since SDL 3.2.0.
2409 */
2410#define SDL_HINT_JOYSTICK_RAWINPUT "SDL_JOYSTICK_RAWINPUT"
2411
2412/**
2413 * A variable controlling whether the RAWINPUT driver should pull correlated
2414 * data from XInput.
2415 *
2416 * The variable can be set to the following values:
2417 *
2418 * - "0": RAWINPUT driver will only use data from raw input APIs.
2419 * - "1": RAWINPUT driver will also pull data from XInput and
2420 * Windows.Gaming.Input, providing better trigger axes, guide button
2421 * presses, and rumble support for Xbox controllers. (default)
2422 *
2423 * This hint should be set before a gamepad is opened.
2424 *
2425 * \since This hint is available since SDL 3.2.0.
2426 */
2427#define SDL_HINT_JOYSTICK_RAWINPUT_CORRELATE_XINPUT "SDL_JOYSTICK_RAWINPUT_CORRELATE_XINPUT"
2428
2429/**
2430 * A variable controlling whether the ROG Chakram mice should show up as
2431 * joysticks.
2432 *
2433 * The variable can be set to the following values:
2434 *
2435 * - "0": ROG Chakram mice do not show up as joysticks. (default)
2436 * - "1": ROG Chakram mice show up as joysticks.
2437 *
2438 * This hint should be set before SDL is initialized.
2439 *
2440 * \since This hint is available since SDL 3.2.0.
2441 */
2442#define SDL_HINT_JOYSTICK_ROG_CHAKRAM "SDL_JOYSTICK_ROG_CHAKRAM"
2443
2444/**
2445 * A variable controlling whether a separate thread should be used for
2446 * handling joystick detection and raw input messages on Windows.
2447 *
2448 * The variable can be set to the following values:
2449 *
2450 * - "0": A separate thread is not used.
2451 * - "1": A separate thread is used for handling raw input messages. (default)
2452 *
2453 * This hint should be set before SDL is initialized.
2454 *
2455 * \since This hint is available since SDL 3.2.0.
2456 */
2457#define SDL_HINT_JOYSTICK_THREAD "SDL_JOYSTICK_THREAD"
2458
2459/**
2460 * A variable containing a list of throttle style controllers.
2461 *
2462 * The format of the string is a comma separated list of USB VID/PID pairs in
2463 * hexadecimal form, e.g.
2464 *
2465 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
2466 *
2467 * The variable can also take the form of "@file", in which case the named
2468 * file will be loaded and interpreted as the value of the variable.
2469 *
2470 * This hint can be set anytime.
2471 *
2472 * \since This hint is available since SDL 3.2.0.
2473 */
2474#define SDL_HINT_JOYSTICK_THROTTLE_DEVICES "SDL_JOYSTICK_THROTTLE_DEVICES"
2475
2476/**
2477 * A variable containing a list of devices that are not throttle style
2478 * controllers.
2479 *
2480 * This will override SDL_HINT_JOYSTICK_THROTTLE_DEVICES and the built in
2481 * device list.
2482 *
2483 * The format of the string is a comma separated list of USB VID/PID pairs in
2484 * hexadecimal form, e.g.
2485 *
2486 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
2487 *
2488 * The variable can also take the form of "@file", in which case the named
2489 * file will be loaded and interpreted as the value of the variable.
2490 *
2491 * This hint can be set anytime.
2492 *
2493 * \since This hint is available since SDL 3.2.0.
2494 */
2495#define SDL_HINT_JOYSTICK_THROTTLE_DEVICES_EXCLUDED "SDL_JOYSTICK_THROTTLE_DEVICES_EXCLUDED"
2496
2497/**
2498 * A variable controlling whether Windows.Gaming.Input should be used for
2499 * controller handling.
2500 *
2501 * The variable can be set to the following values:
2502 *
2503 * - "0": WGI is not used. (default)
2504 * - "1": WGI is used.
2505 *
2506 * This hint should be set before SDL is initialized.
2507 *
2508 * \since This hint is available since SDL 3.2.0.
2509 */
2510#define SDL_HINT_JOYSTICK_WGI "SDL_JOYSTICK_WGI"
2511
2512/**
2513 * A variable containing a list of wheel style controllers.
2514 *
2515 * The format of the string is a comma separated list of USB VID/PID pairs in
2516 * hexadecimal form, e.g.
2517 *
2518 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
2519 *
2520 * The variable can also take the form of "@file", in which case the named
2521 * file will be loaded and interpreted as the value of the variable.
2522 *
2523 * This hint can be set anytime.
2524 *
2525 * \since This hint is available since SDL 3.2.0.
2526 */
2527#define SDL_HINT_JOYSTICK_WHEEL_DEVICES "SDL_JOYSTICK_WHEEL_DEVICES"
2528
2529/**
2530 * A variable containing a list of devices that are not wheel style
2531 * controllers.
2532 *
2533 * This will override SDL_HINT_JOYSTICK_WHEEL_DEVICES and the built in device
2534 * list.
2535 *
2536 * The format of the string is a comma separated list of USB VID/PID pairs in
2537 * hexadecimal form, e.g.
2538 *
2539 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
2540 *
2541 * The variable can also take the form of "@file", in which case the named
2542 * file will be loaded and interpreted as the value of the variable.
2543 *
2544 * This hint can be set anytime.
2545 *
2546 * \since This hint is available since SDL 3.2.0.
2547 */
2548#define SDL_HINT_JOYSTICK_WHEEL_DEVICES_EXCLUDED "SDL_JOYSTICK_WHEEL_DEVICES_EXCLUDED"
2549
2550/**
2551 * A variable containing a list of devices known to have all axes centered at
2552 * zero.
2553 *
2554 * The format of the string is a comma separated list of USB VID/PID pairs in
2555 * hexadecimal form, e.g.
2556 *
2557 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
2558 *
2559 * The variable can also take the form of "@file", in which case the named
2560 * file will be loaded and interpreted as the value of the variable.
2561 *
2562 * This hint should be set before a controller is opened.
2563 *
2564 * \since This hint is available since SDL 3.2.0.
2565 */
2566#define SDL_HINT_JOYSTICK_ZERO_CENTERED_DEVICES "SDL_JOYSTICK_ZERO_CENTERED_DEVICES"
2567
2568/**
2569 * A variable containing a list of devices and their desired number of haptic
2570 * (force feedback) enabled axis.
2571 *
2572 * The format of the string is a comma separated list of USB VID/PID pairs in
2573 * hexadecimal form plus the number of desired axes, e.g.
2574 *
2575 * `0xAAAA/0xBBBB/1,0xCCCC/0xDDDD/3`
2576 *
2577 * This hint supports a "wildcard" device that will set the number of haptic
2578 * axes on all initialized haptic devices which were not defined explicitly in
2579 * this hint.
2580 *
2581 * `0xFFFF/0xFFFF/1`
2582 *
2583 * This hint should be set before a controller is opened. The number of haptic
2584 * axes won't exceed the number of real axes found on the device.
2585 *
2586 * \since This hint is available since SDL 3.2.5.
2587 */
2588#define SDL_HINT_JOYSTICK_HAPTIC_AXES "SDL_JOYSTICK_HAPTIC_AXES"
2589
2590/**
2591 * A variable that controls keycode representation in keyboard events.
2592 *
2593 * This variable is a comma separated set of options for translating keycodes
2594 * in events:
2595 *
2596 * - "none": Keycode options are cleared, this overrides other options.
2597 * - "hide_numpad": The numpad keysyms will be translated into their
2598 * non-numpad versions based on the current NumLock state. For example,
2599 * SDLK_KP_4 would become SDLK_4 if SDL_KMOD_NUM is set in the event
2600 * modifiers, and SDLK_LEFT if it is unset.
2601 * - "french_numbers": The number row on French keyboards is inverted, so
2602 * pressing the 1 key would yield the keycode SDLK_1, or '1', instead of
2603 * SDLK_AMPERSAND, or '&'
2604 * - "latin_letters": For keyboards using non-Latin letters, such as Russian
2605 * or Thai, the letter keys generate keycodes as though it had an English
2606 * QWERTY layout. e.g. pressing the key associated with SDL_SCANCODE_A on a
2607 * Russian keyboard would yield 'a' instead of a Cyrillic letter.
2608 *
2609 * The default value for this hint is "french_numbers,latin_letters"
2610 *
2611 * Some platforms like Emscripten only provide modified keycodes and the
2612 * options are not used.
2613 *
2614 * These options do not affect the return value of SDL_GetKeyFromScancode() or
2615 * SDL_GetScancodeFromKey(), they just apply to the keycode included in key
2616 * events.
2617 *
2618 * This hint can be set anytime.
2619 *
2620 * \since This hint is available since SDL 3.2.0.
2621 */
2622#define SDL_HINT_KEYCODE_OPTIONS "SDL_KEYCODE_OPTIONS"
2623
2624/**
2625 * A variable that controls what KMSDRM device to use.
2626 *
2627 * SDL might open something like "/dev/dri/cardNN" to access KMSDRM
2628 * functionality, where "NN" is a device index number. SDL makes a guess at
2629 * the best index to use (usually zero), but the app or user can set this hint
2630 * to a number between 0 and 99 to force selection.
2631 *
2632 * This hint should be set before SDL is initialized.
2633 *
2634 * \since This hint is available since SDL 3.2.0.
2635 */
2636#define SDL_HINT_KMSDRM_DEVICE_INDEX "SDL_KMSDRM_DEVICE_INDEX"
2637
2638/**
2639 * A variable that controls whether SDL requires DRM master access in order to
2640 * initialize the KMSDRM video backend.
2641 *
2642 * The DRM subsystem has a concept of a "DRM master" which is a DRM client
2643 * that has the ability to set planes, set cursor, etc. When SDL is DRM
2644 * master, it can draw to the screen using the SDL rendering APIs. Without DRM
2645 * master, SDL is still able to process input and query attributes of attached
2646 * displays, but it cannot change display state or draw to the screen
2647 * directly.
2648 *
2649 * In some cases, it can be useful to have the KMSDRM backend even if it
2650 * cannot be used for rendering. An app may want to use SDL for input
2651 * processing while using another rendering API (such as an MMAL overlay on
2652 * Raspberry Pi) or using its own code to render to DRM overlays that SDL
2653 * doesn't support.
2654 *
2655 * The variable can be set to the following values:
2656 *
2657 * - "0": SDL will allow usage of the KMSDRM backend without DRM master.
2658 * - "1": SDL Will require DRM master to use the KMSDRM backend. (default)
2659 *
2660 * This hint should be set before SDL is initialized.
2661 *
2662 * \since This hint is available since SDL 3.2.0.
2663 */
2664#define SDL_HINT_KMSDRM_REQUIRE_DRM_MASTER "SDL_KMSDRM_REQUIRE_DRM_MASTER"
2665
2666/**
2667 * A variable that controls whether KMSDRM will use "atomic" functionality.
2668 *
2669 * The KMSDRM backend can use atomic commits, if both DRM_CLIENT_CAP_ATOMIC
2670 * and DRM_CLIENT_CAP_UNIVERSAL_PLANES is supported by the system. As of SDL
2671 * 3.4.0, it will favor this functionality, but in case this doesn't work well
2672 * on a given system or other surprises, this hint can be used to disable it.
2673 *
2674 * This hint can not enable the functionality if it isn't available.
2675 *
2676 * The variable can be set to the following values:
2677 *
2678 * - "0": SDL will not use the KMSDRM "atomic" functionality.
2679 * - "1": SDL will allow usage of the KMSDRM "atomic" functionality. (default)
2680 *
2681 * This hint should be set before SDL is initialized.
2682 *
2683 * \since This hint is available since SDL 3.4.0.
2684 */
2685#define SDL_HINT_KMSDRM_ATOMIC "SDL_KMSDRM_ATOMIC"
2686
2687/**
2688 * A variable controlling the default SDL log levels.
2689 *
2690 * This variable is a comma separated set of category=level tokens that define
2691 * the default logging levels for SDL applications.
2692 *
2693 * The category can be a numeric category, one of "app", "error", "assert",
2694 * "system", "audio", "video", "render", "input", "test", or `*` for any
2695 * unspecified category.
2696 *
2697 * The level can be a numeric level, one of "verbose", "debug", "info",
2698 * "warn", "error", "critical", or "quiet" to disable that category.
2699 *
2700 * You can omit the category if you want to set the logging level for all
2701 * categories.
2702 *
2703 * If this hint isn't set, the default log levels are equivalent to:
2704 *
2705 * `app=info,assert=warn,test=verbose,*=error`
2706 *
2707 * If the `DEBUG_INVOCATION` environment variable is set to "1", the default
2708 * log levels are equivalent to:
2709 *
2710 * `assert=warn,test=verbose,*=debug`
2711 *
2712 * This hint can be set anytime.
2713 *
2714 * \since This hint is available since SDL 3.2.0.
2715 */
2716#define SDL_HINT_LOGGING "SDL_LOGGING"
2717
2718/**
2719 * A variable controlling whether to force the application to become the
2720 * foreground process when launched on macOS.
2721 *
2722 * The variable can be set to the following values:
2723 *
2724 * - "0": The application is brought to the foreground when launched.
2725 * (default)
2726 * - "1": The application may remain in the background when launched.
2727 *
2728 * This hint needs to be set before SDL_Init().
2729 *
2730 * \since This hint is available since SDL 3.2.0.
2731 */
2732#define SDL_HINT_MAC_BACKGROUND_APP "SDL_MAC_BACKGROUND_APP"
2733
2734/**
2735 * A variable that determines whether Ctrl+Click should generate a right-click
2736 * event on macOS.
2737 *
2738 * The variable can be set to the following values:
2739 *
2740 * - "0": Ctrl+Click does not generate a right mouse button click event.
2741 * (default)
2742 * - "1": Ctrl+Click generated a right mouse button click event.
2743 *
2744 * This hint can be set anytime.
2745 *
2746 * \since This hint is available since SDL 3.2.0.
2747 */
2748#define SDL_HINT_MAC_CTRL_CLICK_EMULATE_RIGHT_CLICK "SDL_MAC_CTRL_CLICK_EMULATE_RIGHT_CLICK"
2749
2750/**
2751 * A variable controlling whether dispatching OpenGL context updates should
2752 * block the dispatching thread until the main thread finishes processing on
2753 * macOS.
2754 *
2755 * The variable can be set to the following values:
2756 *
2757 * - "0": Dispatching OpenGL context updates will block the dispatching thread
2758 * until the main thread finishes processing. (default)
2759 * - "1": Dispatching OpenGL context updates will allow the dispatching thread
2760 * to continue execution.
2761 *
2762 * Generally you want the default, but if you have OpenGL code in a background
2763 * thread on a Mac, and the main thread hangs because it's waiting for that
2764 * background thread, but that background thread is also hanging because it's
2765 * waiting for the main thread to do an update, this might fix your issue.
2766 *
2767 * This hint can be set anytime.
2768 *
2769 * \since This hint is available since SDL 3.2.0.
2770 */
2771#define SDL_HINT_MAC_OPENGL_ASYNC_DISPATCH "SDL_MAC_OPENGL_ASYNC_DISPATCH"
2772
2773/**
2774 * A variable controlling whether the Option key on macOS should be remapped
2775 * to act as the Alt key.
2776 *
2777 * The variable can be set to the following values:
2778 *
2779 * - "none": The Option key is not remapped to Alt. (default)
2780 * - "only_left": Only the left Option key is remapped to Alt.
2781 * - "only_right": Only the right Option key is remapped to Alt.
2782 * - "both": Both Option keys are remapped to Alt.
2783 *
2784 * This will prevent the triggering of key compositions that rely on the
2785 * Option key, but will still send the Alt modifier for keyboard events. In
2786 * the case that both Alt and Option are pressed, the Option key will be
2787 * ignored. This is particularly useful for applications like terminal
2788 * emulators and graphical user interfaces (GUIs) that rely on Alt key
2789 * functionality for shortcuts or navigation. This does not apply to
2790 * SDL_GetKeyFromScancode and only has an effect if IME is enabled.
2791 *
2792 * This hint can be set anytime.
2793 *
2794 * \since This hint is available since SDL 3.2.0.
2795 */
2796#define SDL_HINT_MAC_OPTION_AS_ALT "SDL_MAC_OPTION_AS_ALT"
2797
2798/**
2799 * A variable controlling whether SDL_EVENT_MOUSE_WHEEL event values will have
2800 * momentum on macOS.
2801 *
2802 * The variable can be set to the following values:
2803 *
2804 * - "0": The mouse wheel events will have no momentum. (default)
2805 * - "1": The mouse wheel events will have momentum.
2806 *
2807 * This hint needs to be set before SDL_Init().
2808 *
2809 * \since This hint is available since SDL 3.2.0.
2810 */
2811#define SDL_HINT_MAC_SCROLL_MOMENTUM "SDL_MAC_SCROLL_MOMENTUM"
2812
2813/**
2814 * A variable controlling whether holding down a key will repeat the pressed
2815 * key or open the accents menu on macOS.
2816 *
2817 * The variable can be set to the following values:
2818 *
2819 * - "0": Holding a key will repeat the pressed key.
2820 * - "1": Holding a key will open the accents menu for that key. (default)
2821 *
2822 * This hint needs to be set before SDL_Init().
2823 *
2824 * \since This hint is available since SDL 3.4.0.
2825 */
2826#define SDL_HINT_MAC_PRESS_AND_HOLD "SDL_MAC_PRESS_AND_HOLD"
2827
2828/**
2829 * Request SDL_AppIterate() be called at a specific rate.
2830 *
2831 * If this is set to a number, it represents Hz, so "60" means try to iterate
2832 * 60 times per second. "0" means to iterate as fast as possible. Negative
2833 * values are illegal, but reserved, in case they are useful in a future
2834 * revision of SDL.
2835 *
2836 * There are other strings that have special meaning. If set to "waitevent",
2837 * SDL_AppIterate will not be called until new event(s) have arrived (and been
2838 * processed by SDL_AppEvent). This can be useful for apps that are completely
2839 * idle except in response to input. As of SDL 3.6.0, SDL will allow a single
2840 * call to SDL_AppIterate to proceed without an event immediately after this
2841 * hint is set to "waitevent", so apps can have a minimum of activity, perhaps
2842 * to render an initial image to a window before the user has otherwise
2843 * interacted with the app.
2844 *
2845 * On some platforms, or if you are using SDL_main instead of SDL_AppIterate,
2846 * this hint is ignored. When the hint can be used, it is allowed to be
2847 * changed at any time.
2848 *
2849 * This defaults to 0, and specifying NULL for the hint's value will restore
2850 * the default.
2851 *
2852 * This doesn't have to be an integer value. For example, "59.94" won't be
2853 * rounded to an integer rate; the digits after the decimal are actually
2854 * respected.
2855 *
2856 * This hint can be set anytime.
2857 *
2858 * \since This hint is available since SDL 3.2.0.
2859 */
2860#define SDL_HINT_MAIN_CALLBACK_RATE "SDL_MAIN_CALLBACK_RATE"
2861
2862/**
2863 * A variable controlling whether the mouse is captured while mouse buttons
2864 * are pressed.
2865 *
2866 * The variable can be set to the following values:
2867 *
2868 * - "0": The mouse is not captured while mouse buttons are pressed.
2869 * - "1": The mouse is captured while mouse buttons are pressed.
2870 *
2871 * By default the mouse is captured while mouse buttons are pressed so if the
2872 * mouse is dragged outside the window, the application continues to receive
2873 * mouse events until the button is released.
2874 *
2875 * This hint can be set anytime.
2876 *
2877 * \since This hint is available since SDL 3.2.0.
2878 */
2879#define SDL_HINT_MOUSE_AUTO_CAPTURE "SDL_MOUSE_AUTO_CAPTURE"
2880
2881/**
2882 * A variable setting the double click radius, in pixels.
2883 *
2884 * This hint can be set anytime.
2885 *
2886 * \since This hint is available since SDL 3.2.0.
2887 */
2888#define SDL_HINT_MOUSE_DOUBLE_CLICK_RADIUS "SDL_MOUSE_DOUBLE_CLICK_RADIUS"
2889
2890/**
2891 * A variable setting the double click time, in milliseconds.
2892 *
2893 * This hint can be set anytime.
2894 *
2895 * \since This hint is available since SDL 3.2.0.
2896 */
2897#define SDL_HINT_MOUSE_DOUBLE_CLICK_TIME "SDL_MOUSE_DOUBLE_CLICK_TIME"
2898
2899/**
2900 * A variable setting which system cursor to use as the default cursor.
2901 *
2902 * This should be an integer corresponding to the SDL_SystemCursor enum. The
2903 * default value is zero (SDL_SYSTEM_CURSOR_DEFAULT).
2904 *
2905 * This hint needs to be set before SDL_Init().
2906 *
2907 * \since This hint is available since SDL 3.2.0.
2908 */
2909#define SDL_HINT_MOUSE_DEFAULT_SYSTEM_CURSOR "SDL_MOUSE_DEFAULT_SYSTEM_CURSOR"
2910
2911/**
2912 * A variable setting whether we should scale cursors by the current display
2913 * scale.
2914 *
2915 * The variable can be set to the following values:
2916 *
2917 * - "0": Cursors will not change size based on the display content scale.
2918 * (default)
2919 * - "1": Cursors will automatically match the display content scale (e.g. a
2920 * 2x sized cursor will be used when the window is on a monitor with 200%
2921 * scale). This is currently implemented on Windows.
2922 *
2923 * This hint needs to be set before creating cursors.
2924 *
2925 * \since This hint is available since SDL 3.4.0.
2926 */
2927#define SDL_HINT_MOUSE_DPI_SCALE_CURSORS "SDL_MOUSE_DPI_SCALE_CURSORS"
2928
2929/**
2930 * A variable controlling whether warping a hidden mouse cursor will activate
2931 * relative mouse mode.
2932 *
2933 * When this hint is set, the mouse cursor is hidden, and multiple warps to
2934 * the window center occur within a short time period, SDL will emulate mouse
2935 * warps using relative mouse mode. This can provide smoother and more
2936 * reliable mouse motion for some older games, which continuously calculate
2937 * the distance traveled by the mouse pointer and warp it back to the center
2938 * of the window, rather than using relative mouse motion.
2939 *
2940 * Note that relative mouse mode may have different mouse acceleration
2941 * behavior than pointer warps.
2942 *
2943 * If your application needs to repeatedly warp the hidden mouse cursor at a
2944 * high-frequency for other purposes, it should disable this hint.
2945 *
2946 * The variable can be set to the following values:
2947 *
2948 * - "0": Attempts to warp the mouse will always be made.
2949 * - "1": Some mouse warps will be emulated by forcing relative mouse mode.
2950 * (default)
2951 *
2952 * If not set, this is automatically enabled unless an application uses
2953 * relative mouse mode directly.
2954 *
2955 * This hint can be set anytime.
2956 *
2957 * \since This hint is available since SDL 3.2.0.
2958 */
2959#define SDL_HINT_MOUSE_EMULATE_WARP_WITH_RELATIVE "SDL_MOUSE_EMULATE_WARP_WITH_RELATIVE"
2960
2961/**
2962 * Allow mouse click events when clicking to focus an SDL window.
2963 *
2964 * The variable can be set to the following values:
2965 *
2966 * - "0": Ignore mouse clicks that activate a window. (default)
2967 * - "1": Generate events for mouse clicks that activate a window.
2968 *
2969 * This hint can be set anytime.
2970 *
2971 * \since This hint is available since SDL 3.2.0.
2972 */
2973#define SDL_HINT_MOUSE_FOCUS_CLICKTHROUGH "SDL_MOUSE_FOCUS_CLICKTHROUGH"
2974
2975/**
2976 * A variable setting the speed scale for mouse motion, in floating point,
2977 * when the mouse is not in relative mode.
2978 *
2979 * This hint can be set anytime.
2980 *
2981 * \since This hint is available since SDL 3.2.0.
2982 */
2983#define SDL_HINT_MOUSE_NORMAL_SPEED_SCALE "SDL_MOUSE_NORMAL_SPEED_SCALE"
2984
2985/**
2986 * A variable controlling whether relative mouse mode constrains the mouse to
2987 * the center of the window.
2988 *
2989 * Constraining to the center of the window works better for FPS games and
2990 * when the application is running over RDP. Constraining to the whole window
2991 * works better for 2D games and increases the chance that the mouse will be
2992 * in the correct position when using high DPI mice.
2993 *
2994 * The variable can be set to the following values:
2995 *
2996 * - "0": Relative mouse mode constrains the mouse to the window.
2997 * - "1": Relative mouse mode constrains the mouse to the center of the
2998 * window. (default)
2999 *
3000 * This hint can be set anytime.
3001 *
3002 * \since This hint is available since SDL 3.2.0.
3003 */
3004#define SDL_HINT_MOUSE_RELATIVE_MODE_CENTER "SDL_MOUSE_RELATIVE_MODE_CENTER"
3005
3006/**
3007 * A variable setting the scale for mouse motion, in floating point, when the
3008 * mouse is in relative mode.
3009 *
3010 * This hint can be set anytime.
3011 *
3012 * \since This hint is available since SDL 3.2.0.
3013 */
3014#define SDL_HINT_MOUSE_RELATIVE_SPEED_SCALE "SDL_MOUSE_RELATIVE_SPEED_SCALE"
3015
3016/**
3017 * A variable controlling whether the system mouse acceleration curve is used
3018 * for relative mouse motion.
3019 *
3020 * The variable can be set to the following values:
3021 *
3022 * - "0": Relative mouse motion will be unscaled. (default)
3023 * - "1": Relative mouse motion will be scaled using the system mouse
3024 * acceleration curve.
3025 *
3026 * If SDL_HINT_MOUSE_RELATIVE_SPEED_SCALE is set, that will be applied after
3027 * system speed scale.
3028 *
3029 * This hint can be set anytime.
3030 *
3031 * \since This hint is available since SDL 3.2.0.
3032 */
3033#define SDL_HINT_MOUSE_RELATIVE_SYSTEM_SCALE "SDL_MOUSE_RELATIVE_SYSTEM_SCALE"
3034
3035/**
3036 * A variable controlling whether a motion event should be generated for mouse
3037 * warping in relative mode.
3038 *
3039 * The variable can be set to the following values:
3040 *
3041 * - "0": Warping the mouse will not generate a motion event in relative mode
3042 * - "1": Warping the mouse will generate a motion event in relative mode
3043 *
3044 * By default warping the mouse will not generate motion events in relative
3045 * mode. This avoids the application having to filter out large relative
3046 * motion due to warping.
3047 *
3048 * This hint can be set anytime.
3049 *
3050 * \since This hint is available since SDL 3.2.0.
3051 */
3052#define SDL_HINT_MOUSE_RELATIVE_WARP_MOTION "SDL_MOUSE_RELATIVE_WARP_MOTION"
3053
3054/**
3055 * A variable controlling whether the hardware cursor stays visible when
3056 * relative mode is active.
3057 *
3058 * This variable can be set to the following values:
3059 *
3060 * - "0": The cursor will be hidden while relative mode is active (default)
3061 * - "1": The cursor will remain visible while relative mode is active
3062 *
3063 * Note that for systems without raw hardware inputs, relative mode is
3064 * implemented using warping, so the hardware cursor will visibly warp between
3065 * frames if this is enabled on those systems.
3066 *
3067 * This hint can be set anytime.
3068 *
3069 * \since This hint is available since SDL 3.2.0.
3070 */
3071#define SDL_HINT_MOUSE_RELATIVE_CURSOR_VISIBLE "SDL_MOUSE_RELATIVE_CURSOR_VISIBLE"
3072
3073/**
3074 * A variable controlling whether mouse events should generate synthetic touch
3075 * events.
3076 *
3077 * The variable can be set to the following values:
3078 *
3079 * - "0": Mouse events will not generate touch events. (default for desktop
3080 * platforms)
3081 * - "1": Mouse events will generate touch events. (default for mobile
3082 * platforms, such as Android and iOS)
3083 *
3084 * This hint can be set anytime.
3085 *
3086 * \since This hint is available since SDL 3.2.0.
3087 */
3088#define SDL_HINT_MOUSE_TOUCH_EVENTS "SDL_MOUSE_TOUCH_EVENTS"
3089
3090/**
3091 * A variable controlling whether the keyboard should be muted on the console.
3092 *
3093 * Normally the keyboard is muted while SDL applications are running so that
3094 * keyboard input doesn't show up as key strokes on the console. This hint
3095 * allows you to turn that off for debugging purposes.
3096 *
3097 * The variable can be set to the following values:
3098 *
3099 * - "0": Allow keystrokes to go through to the console.
3100 * - "1": Mute keyboard input so it doesn't show up on the console. (default)
3101 *
3102 * This hint should be set before SDL is initialized.
3103 *
3104 * \since This hint is available since SDL 3.2.0.
3105 */
3106#define SDL_HINT_MUTE_CONSOLE_KEYBOARD "SDL_MUTE_CONSOLE_KEYBOARD"
3107
3108/**
3109 * Tell SDL not to catch the SIGINT or SIGTERM signals on POSIX platforms.
3110 *
3111 * The variable can be set to the following values:
3112 *
3113 * - "0": SDL will install a SIGINT and SIGTERM handler, and when it catches a
3114 * signal, convert it into an SDL_EVENT_QUIT event. (default)
3115 * - "1": SDL will not install a signal handler at all.
3116 *
3117 * This hint should be set before SDL is initialized.
3118 *
3119 * \since This hint is available since SDL 3.2.0.
3120 */
3121#define SDL_HINT_NO_SIGNAL_HANDLERS "SDL_NO_SIGNAL_HANDLERS"
3122
3123/**
3124 * Specify the OpenGL library to load.
3125 *
3126 * This hint should be set before creating an OpenGL window or creating an
3127 * OpenGL context. If this hint isn't set, SDL will choose a reasonable
3128 * default.
3129 *
3130 * \since This hint is available since SDL 3.2.0.
3131 */
3132#define SDL_HINT_OPENGL_LIBRARY "SDL_OPENGL_LIBRARY"
3133
3134/**
3135 * Specify the EGL library to load.
3136 *
3137 * This hint should be set before creating an OpenGL window or creating an
3138 * OpenGL context. This hint is only considered if SDL is using EGL to manage
3139 * OpenGL contexts. If this hint isn't set, SDL will choose a reasonable
3140 * default.
3141 *
3142 * \since This hint is available since SDL 3.2.0.
3143 */
3144#define SDL_HINT_EGL_LIBRARY "SDL_EGL_LIBRARY"
3145
3146/**
3147 * A variable controlling what driver to use for OpenGL ES contexts.
3148 *
3149 * On some platforms, currently Windows and X11, OpenGL drivers may support
3150 * creating contexts with an OpenGL ES profile. By default SDL uses these
3151 * profiles, when available, otherwise it attempts to load an OpenGL ES
3152 * library, e.g. that provided by the ANGLE project. This variable controls
3153 * whether SDL follows this default behaviour or will always load an OpenGL ES
3154 * library.
3155 *
3156 * Circumstances where this is useful include:
3157 *
3158 * - Testing an app with a particular OpenGL ES implementation, e.g ANGLE, or
3159 * emulator, e.g. those from ARM, Imagination or Qualcomm.
3160 * - Resolving OpenGL ES function addresses at link time by linking with the
3161 * OpenGL ES library instead of querying them at run time with
3162 * SDL_GL_GetProcAddress().
3163 *
3164 * Caution: for an application to work with the default behaviour across
3165 * different OpenGL drivers it must query the OpenGL ES function addresses at
3166 * run time using SDL_GL_GetProcAddress().
3167 *
3168 * This variable is ignored on most platforms because OpenGL ES is native or
3169 * not supported.
3170 *
3171 * The variable can be set to the following values:
3172 *
3173 * - "0": Use ES profile of OpenGL, if available. (default)
3174 * - "1": Load OpenGL ES library using the default library names.
3175 *
3176 * This hint should be set before SDL is initialized.
3177 *
3178 * \since This hint is available since SDL 3.2.0.
3179 */
3180#define SDL_HINT_OPENGL_ES_DRIVER "SDL_OPENGL_ES_DRIVER"
3181
3182/**
3183 * A variable controlling whether to force an sRGB-capable OpenGL context.
3184 *
3185 * At OpenGL context creation time, some platforms can request an sRGB-capable
3186 * context. However, sometimes any form of the request can cause surprising
3187 * results on some drivers, platforms, and hardware. Usually the surprise is
3188 * in the form of rendering that is either a little darker or a little
3189 * brighter than intended.
3190 *
3191 * This hint allows the user to override the app's sRGB requests and either
3192 * force a specific value, or avoid requesting anything at all, depending on
3193 * what makes things work correctly for their system.
3194 *
3195 * This is meant as a fail-safe; apps should probably not explicitly set this,
3196 * and most users should not, either.
3197 *
3198 * Note that some platforms cannot make this request at all, and on all
3199 * platforms this request can be denied by the operating system.
3200 *
3201 * In addition to attempting to obtain the type of sRGB-capable OpenGL context
3202 * requested by this hint, SDL will try to force the state of
3203 * GL_FRAMEBUFFER_SRGB on the new context, if appropriate.
3204 *
3205 * The variable can be set to the following values:
3206 *
3207 * - "0": Force a request for an OpenGL context that is _not_ sRGB-capable.
3208 * - "1": Force a request for an OpenGL context that _is_ sRGB-capable.
3209 * - "skip": Don't make any request for an sRGB-capable context (don't specify
3210 * the attribute at all during context creation time).
3211 * - any other string is undefined behavior.
3212 *
3213 * If unset, or set to an empty string, SDL will make a request using the
3214 * value the app specified with the SDL_GL_FRAMEBUFFER_SRGB_CAPABLE attribute.
3215 *
3216 * This hint should be set before an OpenGL context is created.
3217 *
3218 * \since This hint is available since SDL 3.4.2.
3219 */
3220#define SDL_HINT_OPENGL_FORCE_SRGB_FRAMEBUFFER "SDL_OPENGL_FORCE_SRGB_FRAMEBUFFER"
3221
3222/**
3223 * Mechanism to specify openvr_api library location
3224 *
3225 * By default, when using the OpenVR driver, it will search for the API
3226 * library in the current folder. But, if you wish to use a system API you can
3227 * specify that by using this hint. This should be the full or relative path
3228 * to a .dll on Windows or .so on Linux.
3229 *
3230 * \since This hint is available since SDL 3.2.0.
3231 */
3232#define SDL_HINT_OPENVR_LIBRARY "SDL_OPENVR_LIBRARY"
3233
3234/**
3235 * A variable controlling which orientations are allowed on iOS/Android.
3236 *
3237 * In some circumstances it is necessary to be able to explicitly control
3238 * which UI orientations are allowed.
3239 *
3240 * This variable is a space delimited list of the following values:
3241 *
3242 * - "LandscapeLeft"
3243 * - "LandscapeRight"
3244 * - "Portrait"
3245 * - "PortraitUpsideDown"
3246 *
3247 * This hint should be set before SDL is initialized.
3248 *
3249 * \since This hint is available since SDL 3.2.0.
3250 */
3251#define SDL_HINT_ORIENTATIONS "SDL_ORIENTATIONS"
3252
3253/**
3254 * A variable controlling the use of a sentinel event when polling the event
3255 * queue.
3256 *
3257 * When polling for events, SDL_PumpEvents is used to gather new events from
3258 * devices. If a device keeps producing new events between calls to
3259 * SDL_PumpEvents, a poll loop will become stuck until the new events stop.
3260 * This is most noticeable when moving a high frequency mouse.
3261 *
3262 * The variable can be set to the following values:
3263 *
3264 * - "0": Disable poll sentinels.
3265 * - "1": Enable poll sentinels. (default)
3266 *
3267 * This hint can be set anytime.
3268 *
3269 * \since This hint is available since SDL 3.2.0.
3270 */
3271#define SDL_HINT_POLL_SENTINEL "SDL_POLL_SENTINEL"
3272
3273/**
3274 * Override for SDL_GetPreferredLocales().
3275 *
3276 * If set, this will be favored over anything the OS might report for the
3277 * user's preferred locales. Changing this hint at runtime will not generate a
3278 * SDL_EVENT_LOCALE_CHANGED event (but if you can change the hint, you can
3279 * push your own event, if you want).
3280 *
3281 * The format of this hint is a comma-separated list of language and locale,
3282 * combined with an underscore, as is a common format: "en_GB". Locale is
3283 * optional: "en". So you might have a list like this: "en_GB,jp,es_PT"
3284 *
3285 * This hint can be set anytime.
3286 *
3287 * \since This hint is available since SDL 3.2.0.
3288 */
3289#define SDL_HINT_PREFERRED_LOCALES "SDL_PREFERRED_LOCALES"
3290
3291/**
3292 * A variable that decides whether to send SDL_EVENT_QUIT when closing the
3293 * last window.
3294 *
3295 * The variable can be set to the following values:
3296 *
3297 * - "0": SDL will not send an SDL_EVENT_QUIT event when the last window is
3298 * requesting to close. Note that in this case, there are still other
3299 * legitimate reasons one might get an SDL_EVENT_QUIT event: choosing "Quit"
3300 * from the macOS menu bar, sending a SIGINT (ctrl-c) on Unix, etc.
3301 * - "1": SDL will send a quit event when the last window is requesting to
3302 * close. (default)
3303 *
3304 * If there is at least one active system tray icon, SDL_EVENT_QUIT will
3305 * instead be sent when both the last window will be closed and the last tray
3306 * icon will be destroyed.
3307 *
3308 * This hint can be set anytime.
3309 *
3310 * \since This hint is available since SDL 3.2.0.
3311 */
3312#define SDL_HINT_QUIT_ON_LAST_WINDOW_CLOSE "SDL_QUIT_ON_LAST_WINDOW_CLOSE"
3313
3314/**
3315 * A variable controlling whether the Direct3D device is initialized for
3316 * thread-safe operations.
3317 *
3318 * The variable can be set to the following values:
3319 *
3320 * - "0": Thread-safety is not enabled. (default)
3321 * - "1": Thread-safety is enabled.
3322 *
3323 * This hint should be set before creating a renderer.
3324 *
3325 * \since This hint is available since SDL 3.2.0.
3326 */
3327#define SDL_HINT_RENDER_DIRECT3D_THREADSAFE "SDL_RENDER_DIRECT3D_THREADSAFE"
3328
3329/**
3330 * A variable controlling whether to enable Direct3D 11+'s Debug Layer.
3331 *
3332 * This variable does not have any effect on the Direct3D 9 based renderer.
3333 *
3334 * The variable can be set to the following values:
3335 *
3336 * - "0": Disable Debug Layer use. (default)
3337 * - "1": Enable Debug Layer use.
3338 *
3339 * This hint should be set before creating a renderer.
3340 *
3341 * \since This hint is available since SDL 3.2.0.
3342 */
3343#define SDL_HINT_RENDER_DIRECT3D11_DEBUG "SDL_RENDER_DIRECT3D11_DEBUG"
3344
3345/**
3346 * A variable controlling whether to use the Direct3D 11 WARP software
3347 * rasterizer.
3348 *
3349 * For more information, see:
3350 * https://learn.microsoft.com/en-us/windows/win32/direct3darticles/directx-warp
3351 *
3352 * The variable can be set to the following values:
3353 *
3354 * - "0": Disable WARP rasterizer. (default)
3355 * - "1": Enable WARP rasterizer.
3356 *
3357 * This hint should be set before creating a renderer.
3358 *
3359 * \since This hint is available since SDL 3.4.0.
3360 */
3361#define SDL_HINT_RENDER_DIRECT3D11_WARP "SDL_RENDER_DIRECT3D11_WARP"
3362
3363/**
3364 * A variable controlling whether to enable Vulkan Validation Layers.
3365 *
3366 * This variable can be set to the following values:
3367 *
3368 * - "0": Disable Validation Layer use
3369 * - "1": Enable Validation Layer use
3370 *
3371 * By default, SDL does not use Vulkan Validation Layers.
3372 *
3373 * \since This hint is available since SDL 3.2.0.
3374 */
3375#define SDL_HINT_RENDER_VULKAN_DEBUG "SDL_RENDER_VULKAN_DEBUG"
3376
3377/**
3378 * A variable controlling whether to create the GPU device in debug mode.
3379 *
3380 * This variable can be set to the following values:
3381 *
3382 * - "0": Disable debug mode use (default)
3383 * - "1": Enable debug mode use
3384 *
3385 * This hint should be set before creating a renderer.
3386 *
3387 * \since This hint is available since SDL 3.2.0.
3388 */
3389#define SDL_HINT_RENDER_GPU_DEBUG "SDL_RENDER_GPU_DEBUG"
3390
3391/**
3392 * A variable controlling whether to prefer a low-power GPU on multi-GPU
3393 * systems.
3394 *
3395 * This variable can be set to the following values:
3396 *
3397 * - "0": Prefer high-performance GPU (default)
3398 * - "1": Prefer low-power GPU
3399 *
3400 * This hint should be set before creating a renderer.
3401 *
3402 * \since This hint is available since SDL 3.2.0.
3403 */
3404#define SDL_HINT_RENDER_GPU_LOW_POWER "SDL_RENDER_GPU_LOW_POWER"
3405
3406/**
3407 * A variable specifying which render driver to use.
3408 *
3409 * If the application doesn't pick a specific renderer to use, this variable
3410 * specifies the name of the preferred renderer. If the preferred renderer
3411 * can't be initialized, creating a renderer will fail.
3412 *
3413 * This variable is case insensitive and can be set to the following values:
3414 *
3415 * - "direct3d"
3416 * - "direct3d11"
3417 * - "direct3d12"
3418 * - "opengl"
3419 * - "opengles2"
3420 * - "opengles"
3421 * - "metal"
3422 * - "vulkan"
3423 * - "gpu"
3424 * - "software"
3425 *
3426 * This hint accepts a comma-separated list of driver names, and each will be
3427 * tried in the order listed when creating a renderer until one succeeds or
3428 * all of them fail.
3429 *
3430 * The default varies by platform, but it's the first one in the list that is
3431 * available on the current platform.
3432 *
3433 * This hint should be set before creating a renderer.
3434 *
3435 * \since This hint is available since SDL 3.2.0.
3436 */
3437#define SDL_HINT_RENDER_DRIVER "SDL_RENDER_DRIVER"
3438
3439/**
3440 * A variable controlling how the 2D render API renders lines.
3441 *
3442 * The variable can be set to the following values:
3443 *
3444 * - "0": Use the default line drawing method (Bresenham's line algorithm)
3445 * - "1": Use the driver point API using Bresenham's line algorithm (correct,
3446 * draws many points)
3447 * - "2": Use the driver line API (occasionally misses line endpoints based on
3448 * hardware driver quirks
3449 * - "3": Use the driver geometry API (correct, draws thicker diagonal lines)
3450 *
3451 * This hint should be set before creating a renderer.
3452 *
3453 * \since This hint is available since SDL 3.2.0.
3454 */
3455#define SDL_HINT_RENDER_LINE_METHOD "SDL_RENDER_LINE_METHOD"
3456
3457/**
3458 * A variable controlling whether the Metal render driver select low power
3459 * device over default one.
3460 *
3461 * The variable can be set to the following values:
3462 *
3463 * - "0": Use the preferred OS device. (default)
3464 * - "1": Select a low power device.
3465 *
3466 * This hint should be set before creating a renderer.
3467 *
3468 * \since This hint is available since SDL 3.2.0.
3469 */
3470#define SDL_HINT_RENDER_METAL_PREFER_LOW_POWER_DEVICE "SDL_RENDER_METAL_PREFER_LOW_POWER_DEVICE"
3471
3472/**
3473 * A variable controlling whether updates to the SDL screen surface should be
3474 * synchronized with the vertical refresh, to avoid tearing.
3475 *
3476 * This hint overrides the application preference when creating a renderer.
3477 *
3478 * The variable can be set to the following values:
3479 *
3480 * - "0": Disable vsync. (default)
3481 * - "1": Enable vsync.
3482 *
3483 * This hint should be set before creating a renderer.
3484 *
3485 * \since This hint is available since SDL 3.2.0.
3486 */
3487#define SDL_HINT_RENDER_VSYNC "SDL_RENDER_VSYNC"
3488
3489/**
3490 * A variable to control whether the return key on the soft keyboard should
3491 * hide the soft keyboard on Android and iOS.
3492 *
3493 * This hint sets the default value of SDL_PROP_TEXTINPUT_MULTILINE_BOOLEAN.
3494 *
3495 * The variable can be set to the following values:
3496 *
3497 * - "0": The return key will be handled as a key event. (default)
3498 * - "1": The return key will hide the keyboard.
3499 *
3500 * This hint can be set anytime.
3501 *
3502 * \since This hint is available since SDL 3.2.0.
3503 */
3504#define SDL_HINT_RETURN_KEY_HIDES_IME "SDL_RETURN_KEY_HIDES_IME"
3505
3506/**
3507 * A variable containing a list of ROG gamepad capable mice.
3508 *
3509 * The format of the string is a comma separated list of USB VID/PID pairs in
3510 * hexadecimal form, e.g.
3511 *
3512 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
3513 *
3514 * The variable can also take the form of "@file", in which case the named
3515 * file will be loaded and interpreted as the value of the variable.
3516 *
3517 * This hint should be set before SDL is initialized.
3518 *
3519 * \since This hint is available since SDL 3.2.0.
3520 *
3521 * \sa SDL_HINT_ROG_GAMEPAD_MICE_EXCLUDED
3522 */
3523#define SDL_HINT_ROG_GAMEPAD_MICE "SDL_ROG_GAMEPAD_MICE"
3524
3525/**
3526 * A variable containing a list of devices that are not ROG gamepad capable
3527 * mice.
3528 *
3529 * This will override SDL_HINT_ROG_GAMEPAD_MICE and the built in device list.
3530 *
3531 * The format of the string is a comma separated list of USB VID/PID pairs in
3532 * hexadecimal form, e.g.
3533 *
3534 * `0xAAAA/0xBBBB,0xCCCC/0xDDDD`
3535 *
3536 * The variable can also take the form of "@file", in which case the named
3537 * file will be loaded and interpreted as the value of the variable.
3538 *
3539 * This hint should be set before SDL is initialized.
3540 *
3541 * \since This hint is available since SDL 3.2.0.
3542 */
3543#define SDL_HINT_ROG_GAMEPAD_MICE_EXCLUDED "SDL_ROG_GAMEPAD_MICE_EXCLUDED"
3544
3545/**
3546 * A variable controlling the width of the PS2's framebuffer in pixels.
3547 *
3548 * By default, the variable is "640".
3549 *
3550 * \since This hint is available since SDL 3.4.0.
3551 */
3552#define SDL_HINT_PS2_GS_WIDTH "SDL_PS2_GS_WIDTH"
3553
3554/**
3555 * A variable controlling the height of the PS2's framebuffer in pixels.
3556 *
3557 * By default, the variable is "448".
3558 *
3559 * \since This hint is available since SDL 3.4.0.
3560 */
3561#define SDL_HINT_PS2_GS_HEIGHT "SDL_PS2_GS_HEIGHT"
3562
3563/**
3564 * A variable controlling whether the signal is interlaced or progressive.
3565 *
3566 * The variable can be set to the following values:
3567 *
3568 * - "0": Image is interlaced. (default)
3569 * - "1": Image is progressive.
3570 *
3571 * \since This hint is available since SDL 3.4.0.
3572 */
3573#define SDL_HINT_PS2_GS_PROGRESSIVE "SDL_PS2_GS_PROGRESSIVE"
3574
3575/**
3576 * A variable controlling the video mode of the console.
3577 *
3578 * The variable can be set to the following values:
3579 *
3580 * - "": Console-native. (default)
3581 * - "NTSC": 60hz region.
3582 * - "PAL": 50hz region.
3583 *
3584 * \since This hint is available since SDL 3.4.0.
3585 */
3586#define SDL_HINT_PS2_GS_MODE "SDL_PS2_GS_MODE"
3587
3588/**
3589 * A variable controlling which Dispmanx layer to use on a Raspberry PI.
3590 *
3591 * Also known as Z-order. The variable can take a negative or positive value.
3592 * The default is 10000.
3593 *
3594 * This hint should be set before SDL is initialized.
3595 *
3596 * \since This hint is available since SDL 3.2.0.
3597 */
3598#define SDL_HINT_RPI_VIDEO_LAYER "SDL_RPI_VIDEO_LAYER"
3599
3600/**
3601 * Specify an "activity name" for screensaver inhibition.
3602 *
3603 * Some platforms, notably Linux desktops, list the applications which are
3604 * inhibiting the screensaver or other power-saving features.
3605 *
3606 * This hint lets you specify the "activity name" sent to the OS when
3607 * SDL_DisableScreenSaver() is used (or the screensaver is automatically
3608 * disabled). The contents of this hint are used when the screensaver is
3609 * disabled. You should use a string that describes what your program is doing
3610 * (and, therefore, why the screensaver is disabled). For example, "Playing a
3611 * game" or "Watching a video".
3612 *
3613 * Setting this to "" or leaving it unset will have SDL use a reasonable
3614 * default: "Playing a game" or something similar.
3615 *
3616 * This hint should be set before calling SDL_DisableScreenSaver()
3617 *
3618 * \since This hint is available since SDL 3.2.0.
3619 */
3620#define SDL_HINT_SCREENSAVER_INHIBIT_ACTIVITY_NAME "SDL_SCREENSAVER_INHIBIT_ACTIVITY_NAME"
3621
3622/**
3623 * A variable controlling whether SDL calls dbus_shutdown() on quit.
3624 *
3625 * This is useful as a debug tool to validate memory leaks, but shouldn't ever
3626 * be set in production applications, as other libraries used by the
3627 * application might use dbus under the hood and this can cause crashes if
3628 * they continue after SDL_Quit().
3629 *
3630 * The variable can be set to the following values:
3631 *
3632 * - "0": SDL will not call dbus_shutdown() on quit. (default)
3633 * - "1": SDL will call dbus_shutdown() on quit.
3634 *
3635 * This hint can be set anytime.
3636 *
3637 * \since This hint is available since SDL 3.2.0.
3638 */
3639#define SDL_HINT_SHUTDOWN_DBUS_ON_QUIT "SDL_SHUTDOWN_DBUS_ON_QUIT"
3640
3641/**
3642 * A variable that specifies a backend to use for title storage.
3643 *
3644 * By default, SDL will try all available storage backends in a reasonable
3645 * order until it finds one that can work, but this hint allows the app or
3646 * user to force a specific target, such as "pc" if, say, you are on Steam but
3647 * want to avoid SteamRemoteStorage for title data.
3648 *
3649 * This hint should be set before SDL is initialized.
3650 *
3651 * \since This hint is available since SDL 3.2.0.
3652 */
3653#define SDL_HINT_STORAGE_TITLE_DRIVER "SDL_STORAGE_TITLE_DRIVER"
3654
3655/**
3656 * A variable that specifies a backend to use for user storage.
3657 *
3658 * By default, SDL will try all available storage backends in a reasonable
3659 * order until it finds one that can work, but this hint allows the app or
3660 * user to force a specific target, such as "pc" if, say, you are on Steam but
3661 * want to avoid SteamRemoteStorage for user data.
3662 *
3663 * This hint should be set before SDL is initialized.
3664 *
3665 * \since This hint is available since SDL 3.2.0.
3666 */
3667#define SDL_HINT_STORAGE_USER_DRIVER "SDL_STORAGE_USER_DRIVER"
3668
3669/**
3670 * Specifies whether SDL_THREAD_PRIORITY_TIME_CRITICAL should be treated as
3671 * realtime.
3672 *
3673 * On some platforms, like Linux, a realtime priority thread may be subject to
3674 * restrictions that require special handling by the application. This hint
3675 * exists to let SDL know that the app is prepared to handle said
3676 * restrictions.
3677 *
3678 * On Linux, SDL will apply the following configuration to any thread that
3679 * becomes realtime:
3680 *
3681 * - The SCHED_RESET_ON_FORK bit will be set on the scheduling policy,
3682 * - An RLIMIT_RTTIME budget will be configured to the rtkit specified limit.
3683 * - Exceeding this limit will result in the kernel sending SIGKILL to the
3684 * app, refer to the man pages for more information.
3685 *
3686 * The variable can be set to the following values:
3687 *
3688 * - "0": default platform specific behaviour
3689 * - "1": Force SDL_THREAD_PRIORITY_TIME_CRITICAL to a realtime scheduling
3690 * policy
3691 *
3692 * This hint should be set before calling SDL_SetCurrentThreadPriority()
3693 *
3694 * \since This hint is available since SDL 3.2.0.
3695 */
3696#define SDL_HINT_THREAD_FORCE_REALTIME_TIME_CRITICAL "SDL_THREAD_FORCE_REALTIME_TIME_CRITICAL"
3697
3698/**
3699 * A string specifying additional information to use with
3700 * SDL_SetCurrentThreadPriority.
3701 *
3702 * By default SDL_SetCurrentThreadPriority will make appropriate system
3703 * changes in order to apply a thread priority. For example on systems using
3704 * pthreads the scheduler policy is changed automatically to a policy that
3705 * works well with a given priority. Code which has specific requirements can
3706 * override SDL's default behavior with this hint.
3707 *
3708 * pthread hint values are "current", "other", "fifo" and "rr". Currently no
3709 * other platform hint values are defined but may be in the future.
3710 *
3711 * On Linux, the kernel may send SIGKILL to realtime tasks which exceed the
3712 * distro configured execution budget for rtkit. This budget can be queried
3713 * through RLIMIT_RTTIME after calling SDL_SetCurrentThreadPriority().
3714 *
3715 * This hint should be set before calling SDL_SetCurrentThreadPriority()
3716 *
3717 * \since This hint is available since SDL 3.2.0.
3718 */
3719#define SDL_HINT_THREAD_PRIORITY_POLICY "SDL_THREAD_PRIORITY_POLICY"
3720
3721/**
3722 * A variable that controls the timer resolution, in milliseconds.
3723 *
3724 * The higher resolution the timer, the more frequently the CPU services timer
3725 * interrupts, and the more precise delays are, but this takes up power and
3726 * CPU time. This hint is only used on Windows.
3727 *
3728 * See this blog post for more information:
3729 * http://randomascii.wordpress.com/2013/07/08/windows-timer-resolution-megawatts-wasted/
3730 *
3731 * The default value is "1".
3732 *
3733 * If this variable is set to "0", the system timer resolution is not set.
3734 *
3735 * This hint can be set anytime.
3736 *
3737 * \since This hint is available since SDL 3.2.0.
3738 */
3739#define SDL_HINT_TIMER_RESOLUTION "SDL_TIMER_RESOLUTION"
3740
3741/**
3742 * A variable controlling whether touch events should generate synthetic mouse
3743 * events.
3744 *
3745 * The variable can be set to the following values:
3746 *
3747 * - "0": Touch events will not generate mouse events.
3748 * - "1": Touch events will generate mouse events. (default)
3749 *
3750 * This hint can be set anytime.
3751 *
3752 * \since This hint is available since SDL 3.2.0.
3753 */
3754#define SDL_HINT_TOUCH_MOUSE_EVENTS "SDL_TOUCH_MOUSE_EVENTS"
3755
3756/**
3757 * A variable controlling whether trackpads should be treated as touch
3758 * devices.
3759 *
3760 * On macOS (and possibly other platforms in the future), SDL will report
3761 * touches on a trackpad as mouse input, which is generally what users expect
3762 * from this device; however, these are often actually full multitouch-capable
3763 * touch devices, so it might be preferable to some apps to treat them as
3764 * such.
3765 *
3766 * The variable can be set to the following values:
3767 *
3768 * - "0": Trackpad will send mouse events. (default)
3769 * - "1": Trackpad will send touch events.
3770 *
3771 * This hint should be set before SDL is initialized.
3772 *
3773 * \since This hint is available since SDL 3.2.0.
3774 */
3775#define SDL_HINT_TRACKPAD_IS_TOUCH_ONLY "SDL_TRACKPAD_IS_TOUCH_ONLY"
3776
3777/**
3778 * A variable controlling whether the Android / tvOS remotes should be listed
3779 * as joystick devices, instead of sending keyboard events.
3780 *
3781 * The variable can be set to the following values:
3782 *
3783 * - "0": Remotes send enter/escape/arrow key events.
3784 * - "1": Remotes are available as 2 axis, 2 button joysticks. (default)
3785 *
3786 * This hint should be set before SDL is initialized.
3787 *
3788 * \since This hint is available since SDL 3.2.0.
3789 */
3790#define SDL_HINT_TV_REMOTE_AS_JOYSTICK "SDL_TV_REMOTE_AS_JOYSTICK"
3791
3792/**
3793 * A variable controlling whether the screensaver is enabled.
3794 *
3795 * The variable can be set to the following values:
3796 *
3797 * - "0": Disable screensaver. (default)
3798 * - "1": Enable screensaver.
3799 *
3800 * This hint should be set before SDL is initialized.
3801 *
3802 * \since This hint is available since SDL 3.2.0.
3803 */
3804#define SDL_HINT_VIDEO_ALLOW_SCREENSAVER "SDL_VIDEO_ALLOW_SCREENSAVER"
3805
3806/**
3807 * A comma separated list containing the names of the displays that SDL should
3808 * sort to the front of the display list.
3809 *
3810 * When this hint is set, displays with matching name strings will be
3811 * prioritized in the list of displays, as exposed by calling
3812 * SDL_GetDisplays(), with the first listed becoming the primary display. The
3813 * naming convention can vary depending on the environment, but it is usually
3814 * a connector name (e.g. 'DP-1', 'DP-2', 'HDMI-A-1', etc...).
3815 *
3816 * On Wayland desktops, the connector names associated with displays can be
3817 * found in the `name` property of the info output from `wayland-info -i
3818 * wl_output`. On X11 desktops, the `xrandr` utility can be used to retrieve
3819 * the connector names associated with displays.
3820 *
3821 * This hint is currently supported on the following drivers:
3822 *
3823 * - KMSDRM (kmsdrm)
3824 * - Wayland (wayland)
3825 * - X11 (x11)
3826 *
3827 * This hint should be set before SDL is initialized.
3828 *
3829 * \since This hint is available since SDL 3.2.0.
3830 */
3831#define SDL_HINT_VIDEO_DISPLAY_PRIORITY "SDL_VIDEO_DISPLAY_PRIORITY"
3832
3833/**
3834 * Tell the video driver that we only want a double buffer.
3835 *
3836 * By default, most lowlevel 2D APIs will use a triple buffer scheme that
3837 * wastes no CPU time on waiting for vsync after issuing a flip, but
3838 * introduces a frame of latency. On the other hand, using a double buffer
3839 * scheme instead is recommended for cases where low latency is an important
3840 * factor because we save a whole frame of latency.
3841 *
3842 * We do so by waiting for vsync immediately after issuing a flip, usually
3843 * just after eglSwapBuffers call in the backend's *_SwapWindow function.
3844 *
3845 * This hint is currently supported on the following drivers:
3846 *
3847 * - Raspberry Pi (raspberrypi)
3848 * - Wayland (wayland)
3849 *
3850 * This hint should be set before SDL is initialized.
3851 *
3852 * \since This hint is available since SDL 3.2.0.
3853 */
3854#define SDL_HINT_VIDEO_DOUBLE_BUFFER "SDL_VIDEO_DOUBLE_BUFFER"
3855
3856/**
3857 * A variable that specifies a video backend to use.
3858 *
3859 * By default, SDL will try all available video backends in a reasonable order
3860 * until it finds one that can work, but this hint allows the app or user to
3861 * force a specific target, such as "x11" if, say, you are on Wayland but want
3862 * to try talking to the X server instead.
3863 *
3864 * This hint accepts a comma-separated list of driver names, and each will be
3865 * tried in the order listed during init, until one succeeds or all of them
3866 * fail.
3867 *
3868 * This hint should be set before SDL is initialized.
3869 *
3870 * \since This hint is available since SDL 3.2.0.
3871 */
3872#define SDL_HINT_VIDEO_DRIVER "SDL_VIDEO_DRIVER"
3873
3874/**
3875 * A variable controlling whether the dummy video driver saves output frames.
3876 *
3877 * - "0": Video frames are not saved to disk. (default)
3878 * - "1": Video frames are saved to files in the format "SDL_windowX-Y.bmp",
3879 * where X is the window ID, and Y is the frame number.
3880 *
3881 * This hint can be set anytime.
3882 *
3883 * \since This hint is available since SDL 3.2.0.
3884 */
3885#define SDL_HINT_VIDEO_DUMMY_SAVE_FRAMES "SDL_VIDEO_DUMMY_SAVE_FRAMES"
3886
3887/**
3888 * If eglGetPlatformDisplay fails, fall back to calling eglGetDisplay.
3889 *
3890 * The variable can be set to one of the following values:
3891 *
3892 * - "0": Do not fall back to eglGetDisplay.
3893 * - "1": Fall back to eglGetDisplay if eglGetPlatformDisplay fails. (default)
3894 *
3895 * This hint should be set before SDL is initialized.
3896 *
3897 * \since This hint is available since SDL 3.2.0.
3898 */
3899#define SDL_HINT_VIDEO_EGL_ALLOW_GETDISPLAY_FALLBACK "SDL_VIDEO_EGL_ALLOW_GETDISPLAY_FALLBACK"
3900
3901/**
3902 * A variable controlling whether the OpenGL context should be created with
3903 * EGL.
3904 *
3905 * The variable can be set to the following values:
3906 *
3907 * - "0": Use platform-specific GL context creation API (GLX, WGL, CGL, etc).
3908 * (default)
3909 * - "1": Use EGL
3910 *
3911 * This hint should be set before SDL is initialized.
3912 *
3913 * \since This hint is available since SDL 3.2.0.
3914 */
3915#define SDL_HINT_VIDEO_FORCE_EGL "SDL_VIDEO_FORCE_EGL"
3916
3917/**
3918 * A variable that specifies the policy for fullscreen Spaces on macOS.
3919 *
3920 * The variable can be set to the following values:
3921 *
3922 * - "0": Disable Spaces support (FULLSCREEN_DESKTOP won't use them and
3923 * SDL_WINDOW_RESIZABLE windows won't offer the "fullscreen" button on their
3924 * titlebars).
3925 * - "1": Enable Spaces support (FULLSCREEN_DESKTOP will use them and
3926 * SDL_WINDOW_RESIZABLE windows will offer the "fullscreen" button on their
3927 * titlebars). (default)
3928 *
3929 * This hint should be set before creating a window.
3930 *
3931 * \since This hint is available since SDL 3.2.0.
3932 */
3933#define SDL_HINT_VIDEO_MAC_FULLSCREEN_SPACES "SDL_VIDEO_MAC_FULLSCREEN_SPACES"
3934
3935/**
3936 * A variable that specifies the menu visibility when a window is fullscreen
3937 * in Spaces on macOS.
3938 *
3939 * The variable can be set to the following values:
3940 *
3941 * - "0": The menu will be hidden when the window is in a fullscreen space,
3942 * and not accessible by moving the mouse to the top of the screen.
3943 * - "1": The menu will be accessible when the window is in a fullscreen
3944 * space.
3945 * - "auto": The menu will be hidden if fullscreen mode was toggled on
3946 * programmatically via `SDL_SetWindowFullscreen()`, and accessible if
3947 * fullscreen was entered via the "fullscreen" button on the window title
3948 * bar. (default)
3949 *
3950 * This hint can be set anytime.
3951 *
3952 * \since This hint is available since SDL 3.2.0.
3953 */
3954#define SDL_HINT_VIDEO_MAC_FULLSCREEN_MENU_VISIBILITY "SDL_VIDEO_MAC_FULLSCREEN_MENU_VISIBILITY"
3955
3956/**
3957 * A variable indicating whether the metal layer drawable size should be
3958 * updated for the SDL_EVENT_WINDOW_PIXEL_SIZE_CHANGED event on macOS.
3959 *
3960 * The variable can be set to the following values:
3961 *
3962 * - "0": the metal layer drawable size will not be updated on the
3963 * SDL_EVENT_WINDOW_PIXEL_SIZE_CHANGED event.
3964 * - "1": the metal layer drawable size will be updated on the
3965 * SDL_EVENT_WINDOW_PIXEL_SIZE_CHANGED event. (default)
3966 *
3967 * This hint should be set before SDL_Metal_CreateView called.
3968 *
3969 * \since This hint is available since SDL 3.4.0.
3970 */
3971#define SDL_HINT_VIDEO_METAL_AUTO_RESIZE_DRAWABLE "SDL_VIDEO_METAL_AUTO_RESIZE_DRAWABLE"
3972
3973/**
3974 * A variable controlling whether SDL will attempt to automatically set the
3975 * destination display to a mode most closely matching that of the previous
3976 * display if an exclusive fullscreen window is moved onto it.
3977 *
3978 * The variable can be set to the following values:
3979 *
3980 * - "0": SDL will not attempt to automatically set a matching mode on the
3981 * destination display. If an exclusive fullscreen window is moved to a new
3982 * display, the window will become fullscreen desktop.
3983 * - "1": SDL will attempt to automatically set a mode on the destination
3984 * display that most closely matches the mode of the display that the
3985 * exclusive fullscreen window was previously on. (default)
3986 *
3987 * This hint can be set anytime.
3988 *
3989 * \since This hint is available since SDL 3.4.0.
3990 */
3991#define SDL_HINT_VIDEO_MATCH_EXCLUSIVE_MODE_ON_MOVE "SDL_VIDEO_MATCH_EXCLUSIVE_MODE_ON_MOVE"
3992
3993/**
3994 * A variable controlling whether fullscreen windows are minimized when they
3995 * lose focus.
3996 *
3997 * The variable can be set to the following values:
3998 *
3999 * - "0": Fullscreen windows will not be minimized when they lose focus.
4000 * - "1": Fullscreen windows are minimized when they lose focus.
4001 * - "auto": Fullscreen windows are minimized when they lose focus if they use
4002 * exclusive fullscreen modes, so the desktop video mode is restored.
4003 * (default)
4004 *
4005 * This hint can be set anytime.
4006 *
4007 * \since This hint is available since SDL 3.2.0.
4008 */
4009#define SDL_HINT_VIDEO_MINIMIZE_ON_FOCUS_LOSS "SDL_VIDEO_MINIMIZE_ON_FOCUS_LOSS"
4010
4011/**
4012 * A variable controlling whether the offscreen video driver saves output
4013 * frames.
4014 *
4015 * This only saves frames that are generated using software rendering, not
4016 * accelerated OpenGL rendering.
4017 *
4018 * - "0": Video frames are not saved to disk. (default)
4019 * - "1": Video frames are saved to files in the format "SDL_windowX-Y.bmp",
4020 * where X is the window ID, and Y is the frame number.
4021 *
4022 * This hint can be set anytime.
4023 *
4024 * \since This hint is available since SDL 3.2.0.
4025 */
4026#define SDL_HINT_VIDEO_OFFSCREEN_SAVE_FRAMES "SDL_VIDEO_OFFSCREEN_SAVE_FRAMES"
4027
4028/**
4029 * A variable controlling whether all window operations will block until
4030 * complete.
4031 *
4032 * Window systems that run asynchronously may not have the results of window
4033 * operations that resize or move the window applied immediately upon the
4034 * return of the requesting function. Setting this hint will cause such
4035 * operations to block after every call until the pending operation has
4036 * completed. Setting this to '1' is the equivalent of calling
4037 * SDL_SyncWindow() after every function call.
4038 *
4039 * Be aware that amount of time spent blocking while waiting for window
4040 * operations to complete can be quite lengthy, as animations may have to
4041 * complete, which can take upwards of multiple seconds in some cases.
4042 *
4043 * The variable can be set to the following values:
4044 *
4045 * - "0": Window operations are non-blocking. (default)
4046 * - "1": Window operations will block until completed.
4047 *
4048 * This hint can be set anytime.
4049 *
4050 * \since This hint is available since SDL 3.2.0.
4051 */
4052#define SDL_HINT_VIDEO_SYNC_WINDOW_OPERATIONS "SDL_VIDEO_SYNC_WINDOW_OPERATIONS"
4053
4054/**
4055 * A variable controlling whether the libdecor Wayland backend is allowed to
4056 * be used.
4057 *
4058 * libdecor is used over xdg-shell when xdg-decoration protocol is
4059 * unavailable.
4060 *
4061 * The variable can be set to the following values:
4062 *
4063 * - "0": libdecor use is disabled.
4064 * - "1": libdecor use is enabled. (default)
4065 *
4066 * This hint should be set before SDL is initialized.
4067 *
4068 * \since This hint is available since SDL 3.2.0.
4069 */
4070#define SDL_HINT_VIDEO_WAYLAND_ALLOW_LIBDECOR "SDL_VIDEO_WAYLAND_ALLOW_LIBDECOR"
4071
4072/**
4073 * A variable controlling whether video mode emulation is enabled under
4074 * Wayland.
4075 *
4076 * When this hint is set, a standard set of emulated CVT video modes will be
4077 * exposed for use by the application. If it is disabled, the only modes
4078 * exposed will be the logical desktop size and, in the case of a scaled
4079 * desktop, the native display resolution.
4080 *
4081 * The variable can be set to the following values:
4082 *
4083 * - "0": Video mode emulation is disabled.
4084 * - "1": Video mode emulation is enabled. (default)
4085 *
4086 * This hint should be set before SDL is initialized.
4087 *
4088 * \since This hint is available since SDL 3.2.0.
4089 */
4090#define SDL_HINT_VIDEO_WAYLAND_MODE_EMULATION "SDL_VIDEO_WAYLAND_MODE_EMULATION"
4091
4092/**
4093 * A variable controlling how modes with a non-native aspect ratio are
4094 * displayed under Wayland.
4095 *
4096 * When this hint is set, the requested scaling will be used when displaying
4097 * fullscreen video modes that don't match the display's native aspect ratio.
4098 * This is contingent on compositor viewport support.
4099 *
4100 * The variable can be set to the following values:
4101 *
4102 * - "aspect" - Video modes will be displayed scaled, in their proper aspect
4103 * ratio, with black bars. (default)
4104 * - "stretch" - Video modes will be scaled to fill the entire display.
4105 * - "none" - Video modes will be displayed as 1:1 with no scaling.
4106 *
4107 * This hint should be set before creating a window.
4108 *
4109 * \since This hint is available since SDL 3.2.0.
4110 */
4111#define SDL_HINT_VIDEO_WAYLAND_MODE_SCALING "SDL_VIDEO_WAYLAND_MODE_SCALING"
4112
4113/**
4114 * A variable controlling whether the libdecor Wayland backend is preferred
4115 * over native decorations.
4116 *
4117 * When this hint is set, libdecor will be used to provide window decorations,
4118 * even if xdg-decoration is available. (Note that, by default, libdecor will
4119 * use xdg-decoration itself if available).
4120 *
4121 * The variable can be set to the following values:
4122 *
4123 * - "0": libdecor is enabled only if server-side decorations are unavailable.
4124 * (default)
4125 * - "1": libdecor is always enabled if available.
4126 *
4127 * This hint should be set before SDL is initialized.
4128 *
4129 * \since This hint is available since SDL 3.2.0.
4130 */
4131#define SDL_HINT_VIDEO_WAYLAND_PREFER_LIBDECOR "SDL_VIDEO_WAYLAND_PREFER_LIBDECOR"
4132
4133/**
4134 * A variable forcing non-DPI-aware Wayland windows to output at 1:1 scaling.
4135 *
4136 * This must be set before initializing the video subsystem.
4137 *
4138 * When this hint is set, Wayland windows that are not flagged as being
4139 * DPI-aware will be output with scaling designed to force 1:1 pixel mapping.
4140 *
4141 * This is intended to allow legacy applications to be displayed without
4142 * desktop scaling being applied, and has issues with certain display
4143 * configurations, as this forces the window to behave in a way that Wayland
4144 * desktops were not designed to accommodate:
4145 *
4146 * - Rounding errors can result with odd window sizes and/or desktop scales,
4147 * which can cause the window contents to appear slightly blurry.
4148 * - Positioning the window may be imprecise due to unit conversions and
4149 * rounding.
4150 * - The window may be unusably small on scaled desktops.
4151 * - The window may jump in size when moving between displays of different
4152 * scale factors.
4153 * - Displays may appear to overlap when using a multi-monitor setup with
4154 * scaling enabled.
4155 * - Possible loss of cursor precision due to the logical size of the window
4156 * being reduced.
4157 *
4158 * New applications should be designed with proper DPI awareness handling
4159 * instead of enabling this.
4160 *
4161 * The variable can be set to the following values:
4162 *
4163 * - "0": Windows will be scaled normally.
4164 * - "1": Windows will be forced to scale to achieve 1:1 output.
4165 *
4166 * This hint should be set before creating a window.
4167 *
4168 * \since This hint is available since SDL 3.2.0.
4169 */
4170#define SDL_HINT_VIDEO_WAYLAND_SCALE_TO_DISPLAY "SDL_VIDEO_WAYLAND_SCALE_TO_DISPLAY"
4171
4172/**
4173 * A variable specifying which shader compiler to preload when using the
4174 * Chrome ANGLE binaries.
4175 *
4176 * SDL has EGL and OpenGL ES2 support on Windows via the ANGLE project. It can
4177 * use two different sets of binaries, those compiled by the user from source
4178 * or those provided by the Chrome browser. In the later case, these binaries
4179 * require that SDL loads a DLL providing the shader compiler.
4180 *
4181 * The variable can be set to the following values:
4182 *
4183 * - "d3dcompiler_46.dll" - best for Vista or later. (default)
4184 * - "d3dcompiler_43.dll" - for XP support.
4185 * - "none" - do not load any library, useful if you compiled ANGLE from
4186 * source and included the compiler in your binaries.
4187 *
4188 * This hint should be set before SDL is initialized.
4189 *
4190 * \since This hint is available since SDL 3.2.0.
4191 */
4192#define SDL_HINT_VIDEO_WIN_D3DCOMPILER "SDL_VIDEO_WIN_D3DCOMPILER"
4193
4194/**
4195 * A variable controlling whether the X Synchronization Extension is enabled.
4196 *
4197 * If set, this can result in smoother window resizing when rendering using
4198 * OpenGL, however, there are some conditions:
4199 *
4200 * - It is only activated on windows created with the `SDL_WINDOW_OPENGL` flag
4201 * (windows using an SDL OpenGL renderer have this automatically set).
4202 * - When activated, presentation must be done with `SDL_GL_SwapWindow()`
4203 * (`SDL_RenderPresent()` calls this internally for OpenGL renderers as
4204 * well).
4205 *
4206 * Enabling this and presenting via an external mechanism will result in sync
4207 * requests not being acked, and hangs and other odd window behavior may
4208 * result.
4209 *
4210 * The variable can be set to the following values:
4211 *
4212 * - "0": The X Synchronization Extension is disabled. (default)
4213 * - "1": The X Synchronization Extension is enabled.
4214 *
4215 * This hint should be set before creating a window.
4216 *
4217 * \since This hint is available since SDL 3.4.10.
4218 */
4219#define SDL_HINT_VIDEO_X11_ENABLE_XSYNC_EXT "SDL_VIDEO_X11_ENABLE_XSYNC_EXT"
4220
4221/**
4222 * A variable controlling whether SDL should call XSelectInput() to enable
4223 * input events on X11 windows wrapped by SDL windows.
4224 *
4225 * The variable can be set to the following values:
4226 *
4227 * - "0": Don't call XSelectInput(), assuming the native window code has done
4228 * it already.
4229 * - "1": Call XSelectInput() to enable input events. (default)
4230 *
4231 * This hint should be set before creating a window.
4232 *
4233 * \since This hint is available since SDL 3.2.10.
4234 */
4235#define SDL_HINT_VIDEO_X11_EXTERNAL_WINDOW_INPUT "SDL_VIDEO_X11_EXTERNAL_WINDOW_INPUT"
4236
4237/**
4238 * A variable controlling whether the X11 _NET_WM_BYPASS_COMPOSITOR hint
4239 * should be used.
4240 *
4241 * The variable can be set to the following values:
4242 *
4243 * - "0": Disable _NET_WM_BYPASS_COMPOSITOR.
4244 * - "1": Enable _NET_WM_BYPASS_COMPOSITOR. (default)
4245 *
4246 * This hint should be set before creating a window.
4247 *
4248 * \since This hint is available since SDL 3.2.0.
4249 */
4250#define SDL_HINT_VIDEO_X11_NET_WM_BYPASS_COMPOSITOR "SDL_VIDEO_X11_NET_WM_BYPASS_COMPOSITOR"
4251
4252/**
4253 * A variable controlling whether the X11 _NET_WM_PING protocol should be
4254 * supported.
4255 *
4256 * By default SDL will use _NET_WM_PING, but for applications that know they
4257 * will not always be able to respond to ping requests in a timely manner they
4258 * can turn it off to avoid the window manager thinking the app is hung.
4259 *
4260 * The variable can be set to the following values:
4261 *
4262 * - "0": Disable _NET_WM_PING.
4263 * - "1": Enable _NET_WM_PING. (default)
4264 *
4265 * This hint should be set before creating a window.
4266 *
4267 * \since This hint is available since SDL 3.2.0.
4268 */
4269#define SDL_HINT_VIDEO_X11_NET_WM_PING "SDL_VIDEO_X11_NET_WM_PING"
4270
4271/**
4272 * A variable controlling whether SDL uses DirectColor visuals.
4273 *
4274 * The variable can be set to the following values:
4275 *
4276 * - "0": Disable DirectColor visuals.
4277 * - "1": Enable DirectColor visuals. (default)
4278 *
4279 * This hint should be set before initializing the video subsystem.
4280 *
4281 * \since This hint is available since SDL 3.2.0.
4282 */
4283#define SDL_HINT_VIDEO_X11_NODIRECTCOLOR "SDL_VIDEO_X11_NODIRECTCOLOR"
4284
4285/**
4286 * A variable forcing the content scaling factor for X11 displays.
4287 *
4288 * The variable can be set to a floating point value in the range 1.0-10.0f
4289 *
4290 * This hint should be set before SDL is initialized.
4291 *
4292 * \since This hint is available since SDL 3.2.0.
4293 */
4294#define SDL_HINT_VIDEO_X11_SCALING_FACTOR "SDL_VIDEO_X11_SCALING_FACTOR"
4295
4296/**
4297 * A variable forcing the visual ID used for X11 display modes.
4298 *
4299 * This hint should be set before initializing the video subsystem.
4300 *
4301 * \since This hint is available since SDL 3.2.0.
4302 */
4303#define SDL_HINT_VIDEO_X11_VISUALID "SDL_VIDEO_X11_VISUALID"
4304
4305/**
4306 * A variable forcing the visual ID chosen for new X11 windows.
4307 *
4308 * This hint should be set before creating a window.
4309 *
4310 * \since This hint is available since SDL 3.2.0.
4311 */
4312#define SDL_HINT_VIDEO_X11_WINDOW_VISUALID "SDL_VIDEO_X11_WINDOW_VISUALID"
4313
4314/**
4315 * A variable controlling whether the X11 XRandR extension should be used.
4316 *
4317 * The variable can be set to the following values:
4318 *
4319 * - "0": Disable XRandR.
4320 * - "1": Enable XRandR. (default)
4321 *
4322 * This hint should be set before SDL is initialized.
4323 *
4324 * \since This hint is available since SDL 3.2.0.
4325 */
4326#define SDL_HINT_VIDEO_X11_XRANDR "SDL_VIDEO_X11_XRANDR"
4327
4328/**
4329 * A variable controlling whether the HDR headroom slider should be shown in
4330 * the visionOS window settings.
4331 *
4332 * The variable can be set to the following values:
4333 *
4334 * - "0": The HDR headroom slider is not shown. (default)
4335 * - "1": The HDR headroom slider is shown.
4336 *
4337 * This hint should be set before SDL is initialized.
4338 *
4339 * \since This hint is available since SDL 3.6.0.
4340 */
4341#define SDL_HINT_VISIONOS_HDR_HEADROOM_UI "SDL_VISIONOS_HDR_HEADROOM_UI"
4342
4343/**
4344 * A variable controlling whether touch should be enabled on the back panel of
4345 * the PlayStation Vita.
4346 *
4347 * The variable can be set to the following values:
4348 *
4349 * - "0": Disable touch on the back panel.
4350 * - "1": Enable touch on the back panel. (default)
4351 *
4352 * This hint should be set before SDL is initialized.
4353 *
4354 * \since This hint is available since SDL 3.2.0.
4355 */
4356#define SDL_HINT_VITA_ENABLE_BACK_TOUCH "SDL_VITA_ENABLE_BACK_TOUCH"
4357
4358/**
4359 * A variable controlling whether touch should be enabled on the front panel
4360 * of the PlayStation Vita.
4361 *
4362 * The variable can be set to the following values:
4363 *
4364 * - "0": Disable touch on the front panel.
4365 * - "1": Enable touch on the front panel. (default)
4366 *
4367 * This hint should be set before SDL is initialized.
4368 *
4369 * \since This hint is available since SDL 3.2.0.
4370 */
4371#define SDL_HINT_VITA_ENABLE_FRONT_TOUCH "SDL_VITA_ENABLE_FRONT_TOUCH"
4372
4373/**
4374 * A variable controlling the module path on the PlayStation Vita.
4375 *
4376 * This hint defaults to "app0:module"
4377 *
4378 * This hint should be set before SDL is initialized.
4379 *
4380 * \since This hint is available since SDL 3.2.0.
4381 */
4382#define SDL_HINT_VITA_MODULE_PATH "SDL_VITA_MODULE_PATH"
4383
4384/**
4385 * A variable controlling whether to perform PVR initialization on the
4386 * PlayStation Vita.
4387 *
4388 * - "0": Skip PVR initialization.
4389 * - "1": Perform the normal PVR initialization. (default)
4390 *
4391 * This hint should be set before SDL is initialized.
4392 *
4393 * \since This hint is available since SDL 3.2.0.
4394 */
4395#define SDL_HINT_VITA_PVR_INIT "SDL_VITA_PVR_INIT"
4396
4397/**
4398 * A variable overriding the resolution reported on the PlayStation Vita.
4399 *
4400 * The variable can be set to the following values:
4401 *
4402 * - "544": 544p (default)
4403 * - "720": 725p for PSTV
4404 * - "1080": 1088i for PSTV
4405 *
4406 * This hint should be set before SDL is initialized.
4407 *
4408 * \since This hint is available since SDL 3.2.0.
4409 */
4410#define SDL_HINT_VITA_RESOLUTION "SDL_VITA_RESOLUTION"
4411
4412/**
4413 * A variable controlling whether OpenGL should be used instead of OpenGL ES
4414 * on the PlayStation Vita.
4415 *
4416 * The variable can be set to the following values:
4417 *
4418 * - "0": Use OpenGL ES. (default)
4419 * - "1": Use OpenGL.
4420 *
4421 * This hint should be set before SDL is initialized.
4422 *
4423 * \since This hint is available since SDL 3.2.0.
4424 */
4425#define SDL_HINT_VITA_PVR_OPENGL "SDL_VITA_PVR_OPENGL"
4426
4427/**
4428 * A variable controlling which touchpad should generate synthetic mouse
4429 * events.
4430 *
4431 * The variable can be set to the following values:
4432 *
4433 * - "0": Only front touchpad should generate mouse events. (default)
4434 * - "1": Only back touchpad should generate mouse events.
4435 * - "2": Both touchpads should generate mouse events.
4436 *
4437 * This hint can be set anytime.
4438 *
4439 * \since This hint is available since SDL 3.2.0.
4440 */
4441#define SDL_HINT_VITA_TOUCH_MOUSE_DEVICE "SDL_VITA_TOUCH_MOUSE_DEVICE"
4442
4443/**
4444 * A variable overriding the display index used in SDL_Vulkan_CreateSurface()
4445 *
4446 * The display index starts at 0, which is the default.
4447 *
4448 * This hint should be set before calling SDL_Vulkan_CreateSurface()
4449 *
4450 * \since This hint is available since SDL 3.2.0.
4451 */
4452#define SDL_HINT_VULKAN_DISPLAY "SDL_VULKAN_DISPLAY"
4453
4454/**
4455 * Specify the Vulkan library to load.
4456 *
4457 * This hint should be set before creating a Vulkan window or calling
4458 * SDL_Vulkan_LoadLibrary().
4459 *
4460 * \since This hint is available since SDL 3.2.0.
4461 */
4462#define SDL_HINT_VULKAN_LIBRARY "SDL_VULKAN_LIBRARY"
4463
4464/**
4465 * A variable controlling how the fact chunk affects the loading of a WAVE
4466 * file.
4467 *
4468 * The fact chunk stores information about the number of samples of a WAVE
4469 * file. The Standards Update from Microsoft notes that this value can be used
4470 * to 'determine the length of the data in seconds'. This is especially useful
4471 * for compressed formats (for which this is a mandatory chunk) if they
4472 * produce multiple sample frames per block and truncating the block is not
4473 * allowed. The fact chunk can exactly specify how many sample frames there
4474 * should be in this case.
4475 *
4476 * Unfortunately, most application seem to ignore the fact chunk and so SDL
4477 * ignores it by default as well.
4478 *
4479 * The variable can be set to the following values:
4480 *
4481 * - "truncate" - Use the number of samples to truncate the wave data if the
4482 * fact chunk is present and valid.
4483 * - "strict" - Like "truncate", but raise an error if the fact chunk is
4484 * invalid, not present for non-PCM formats, or if the data chunk doesn't
4485 * have that many samples.
4486 * - "ignorezero" - Like "truncate", but ignore fact chunk if the number of
4487 * samples is zero.
4488 * - "ignore" - Ignore fact chunk entirely. (default)
4489 *
4490 * This hint should be set before calling SDL_LoadWAV() or SDL_LoadWAV_IO()
4491 *
4492 * \since This hint is available since SDL 3.2.0.
4493 */
4494#define SDL_HINT_WAVE_FACT_CHUNK "SDL_WAVE_FACT_CHUNK"
4495
4496/**
4497 * A variable controlling the maximum number of chunks in a WAVE file.
4498 *
4499 * This sets an upper bound on the number of chunks in a WAVE file to avoid
4500 * wasting time on malformed or corrupt WAVE files. This defaults to "10000".
4501 *
4502 * This hint should be set before calling SDL_LoadWAV() or SDL_LoadWAV_IO()
4503 *
4504 * \since This hint is available since SDL 3.2.0.
4505 */
4506#define SDL_HINT_WAVE_CHUNK_LIMIT "SDL_WAVE_CHUNK_LIMIT"
4507
4508/**
4509 * A variable controlling how the size of the RIFF chunk affects the loading
4510 * of a WAVE file.
4511 *
4512 * The size of the RIFF chunk (which includes all the sub-chunks of the WAVE
4513 * file) is not always reliable. In case the size is wrong, it's possible to
4514 * just ignore it and step through the chunks until a fixed limit is reached.
4515 *
4516 * Note that files that have trailing data unrelated to the WAVE file or
4517 * corrupt files may slow down the loading process without a reliable
4518 * boundary. By default, SDL stops after 10000 chunks to prevent wasting time.
4519 * Use SDL_HINT_WAVE_CHUNK_LIMIT to adjust this value.
4520 *
4521 * The variable can be set to the following values:
4522 *
4523 * - "force" - Always use the RIFF chunk size as a boundary for the chunk
4524 * search.
4525 * - "ignorezero" - Like "force", but a zero size searches up to 4 GiB.
4526 * (default)
4527 * - "ignore" - Ignore the RIFF chunk size and always search up to 4 GiB.
4528 * - "maximum" - Search for chunks until the end of file. (not recommended)
4529 *
4530 * This hint should be set before calling SDL_LoadWAV() or SDL_LoadWAV_IO()
4531 *
4532 * \since This hint is available since SDL 3.2.0.
4533 */
4534#define SDL_HINT_WAVE_RIFF_CHUNK_SIZE "SDL_WAVE_RIFF_CHUNK_SIZE"
4535
4536/**
4537 * A variable controlling how a truncated WAVE file is handled.
4538 *
4539 * A WAVE file is considered truncated if any of the chunks are incomplete or
4540 * the data chunk size is not a multiple of the block size. By default, SDL
4541 * decodes until the first incomplete block, as most applications seem to do.
4542 *
4543 * The variable can be set to the following values:
4544 *
4545 * - "verystrict" - Raise an error if the file is truncated.
4546 * - "strict" - Like "verystrict", but the size of the RIFF chunk is ignored.
4547 * - "dropframe" - Decode until the first incomplete sample frame.
4548 * - "dropblock" - Decode until the first incomplete block. (default)
4549 *
4550 * This hint should be set before calling SDL_LoadWAV() or SDL_LoadWAV_IO()
4551 *
4552 * \since This hint is available since SDL 3.2.0.
4553 */
4554#define SDL_HINT_WAVE_TRUNCATION "SDL_WAVE_TRUNCATION"
4555
4556/**
4557 * A variable controlling whether the window is activated when the
4558 * SDL_RaiseWindow function is called.
4559 *
4560 * The variable can be set to the following values:
4561 *
4562 * - "0": The window is not activated when the SDL_RaiseWindow function is
4563 * called.
4564 * - "1": The window is activated when the SDL_RaiseWindow function is called.
4565 * (default)
4566 *
4567 * This hint can be set anytime.
4568 *
4569 * \since This hint is available since SDL 3.2.0.
4570 */
4571#define SDL_HINT_WINDOW_ACTIVATE_WHEN_RAISED "SDL_WINDOW_ACTIVATE_WHEN_RAISED"
4572
4573/**
4574 * A variable controlling whether the window is activated when the
4575 * SDL_ShowWindow function is called.
4576 *
4577 * The variable can be set to the following values:
4578 *
4579 * - "0": The window is not activated when the SDL_ShowWindow function is
4580 * called.
4581 * - "1": The window is activated when the SDL_ShowWindow function is called.
4582 * (default)
4583 *
4584 * This hint can be set anytime.
4585 *
4586 * \since This hint is available since SDL 3.2.0.
4587 */
4588#define SDL_HINT_WINDOW_ACTIVATE_WHEN_SHOWN "SDL_WINDOW_ACTIVATE_WHEN_SHOWN"
4589
4590/**
4591 * If set to "0" then never set the top-most flag on an SDL Window even if the
4592 * application requests it.
4593 *
4594 * This is a debugging aid for developers and not expected to be used by end
4595 * users.
4596 *
4597 * The variable can be set to the following values:
4598 *
4599 * - "0": don't allow topmost
4600 * - "1": allow topmost (default)
4601 *
4602 * This hint can be set anytime.
4603 *
4604 * \since This hint is available since SDL 3.2.0.
4605 */
4606#define SDL_HINT_WINDOW_ALLOW_TOPMOST "SDL_WINDOW_ALLOW_TOPMOST"
4607
4608/**
4609 * A variable controlling whether the window frame and title bar are
4610 * interactive when the cursor is hidden.
4611 *
4612 * The variable can be set to the following values:
4613 *
4614 * - "0": The window frame is not interactive when the cursor is hidden (no
4615 * move, resize, etc).
4616 * - "1": The window frame is interactive when the cursor is hidden. (default)
4617 *
4618 * This hint can be set anytime.
4619 *
4620 * \since This hint is available since SDL 3.2.0.
4621 */
4622#define SDL_HINT_WINDOW_FRAME_USABLE_WHILE_CURSOR_HIDDEN "SDL_WINDOW_FRAME_USABLE_WHILE_CURSOR_HIDDEN"
4623
4624/**
4625 * A variable controlling whether SDL generates window-close events for Alt+F4
4626 * on Windows.
4627 *
4628 * The variable can be set to the following values:
4629 *
4630 * - "0": SDL will only do normal key handling for Alt+F4.
4631 * - "1": SDL will generate a window-close event when it sees Alt+F4.
4632 * (default)
4633 *
4634 * This hint can be set anytime.
4635 *
4636 * \since This hint is available since SDL 3.2.0.
4637 */
4638#define SDL_HINT_WINDOWS_CLOSE_ON_ALT_F4 "SDL_WINDOWS_CLOSE_ON_ALT_F4"
4639
4640/**
4641 * A variable controlling whether menus can be opened with their keyboard
4642 * shortcut (Alt+mnemonic).
4643 *
4644 * If the mnemonics are enabled, then menus can be opened by pressing the Alt
4645 * key and the corresponding mnemonic (for example, Alt+F opens the File
4646 * menu). However, in case an invalid mnemonic is pressed, Windows makes an
4647 * audible beep to convey that nothing happened. This is true even if the
4648 * window has no menu at all!
4649 *
4650 * Because most SDL applications don't have menus, and some want to use the
4651 * Alt key for other purposes, SDL disables mnemonics (and the beeping) by
4652 * default.
4653 *
4654 * Note: This also affects keyboard events: with mnemonics enabled, when a
4655 * menu is opened from the keyboard, you will not receive a KEYUP event for
4656 * the mnemonic key, and *might* not receive one for Alt.
4657 *
4658 * The variable can be set to the following values:
4659 *
4660 * - "0": Alt+mnemonic does nothing, no beeping. (default)
4661 * - "1": Alt+mnemonic opens menus, invalid mnemonics produce a beep.
4662 *
4663 * This hint can be set anytime.
4664 *
4665 * \since This hint is available since SDL 3.2.0.
4666 */
4667#define SDL_HINT_WINDOWS_ENABLE_MENU_MNEMONICS "SDL_WINDOWS_ENABLE_MENU_MNEMONICS"
4668
4669/**
4670 * A variable controlling whether the windows message loop is processed by
4671 * SDL.
4672 *
4673 * The variable can be set to the following values:
4674 *
4675 * - "0": The window message loop is not run.
4676 * - "1": The window message loop is processed in SDL_PumpEvents(). (default)
4677 *
4678 * This hint can be set anytime.
4679 *
4680 * \since This hint is available since SDL 3.2.0.
4681 */
4682#define SDL_HINT_WINDOWS_ENABLE_MESSAGELOOP "SDL_WINDOWS_ENABLE_MESSAGELOOP"
4683
4684/**
4685 * A variable controlling whether GameInput is used for raw keyboard and mouse
4686 * on Windows.
4687 *
4688 * The variable can be set to the following values:
4689 *
4690 * - "0": GameInput is not used for raw keyboard and mouse events. (default)
4691 * - "1": GameInput is used for raw keyboard and mouse events, if available.
4692 *
4693 * This hint should be set before SDL is initialized.
4694 *
4695 * \since This hint is available since SDL 3.2.0.
4696 */
4697#define SDL_HINT_WINDOWS_GAMEINPUT "SDL_WINDOWS_GAMEINPUT"
4698
4699/**
4700 * A variable controlling whether raw keyboard events are used on Windows.
4701 *
4702 * The variable can be set to the following values:
4703 *
4704 * - "0": The Windows message loop is used for keyboard events. (default)
4705 * - "1": Low latency raw keyboard events are used.
4706 *
4707 * This hint can be set anytime.
4708 *
4709 * \since This hint is available since SDL 3.2.0.
4710 */
4711#define SDL_HINT_WINDOWS_RAW_KEYBOARD "SDL_WINDOWS_RAW_KEYBOARD"
4712
4713/**
4714 * A variable controlling whether or not the RIDEV_NOHOTKEYS flag is set when
4715 * enabling Windows raw keyboard events.
4716 *
4717 * This blocks any hotkeys that have been registered by applications from
4718 * having any effect beyond generating raw WM_INPUT events.
4719 *
4720 * This flag does not affect system-hotkeys like ALT-TAB or CTRL-ALT-DEL, but
4721 * does affect the Windows Logo key since it is a userland hotkey registered
4722 * by explorer.exe.
4723 *
4724 * The variable can be set to the following values:
4725 *
4726 * - "0": Hotkeys are not excluded. (default)
4727 * - "1": Hotkeys are excluded.
4728 *
4729 * This hint can be set anytime.
4730 *
4731 * \since This hint is available since SDL 3.4.0.
4732 */
4733#define SDL_HINT_WINDOWS_RAW_KEYBOARD_EXCLUDE_HOTKEYS "SDL_WINDOWS_RAW_KEYBOARD_EXCLUDE_HOTKEYS"
4734
4735/**
4736 * A variable controlling whether the RIDEV_INPUTSINK flag is set when
4737 * enabling Windows raw keyboard events.
4738 *
4739 * This enables the window to still receive input even if not in foreground.
4740 *
4741 * Focused windows that receive text input will still prevent input events
4742 * from triggering.
4743 *
4744 * - "0": Input is not received when not in focus or foreground. (default)
4745 * - "1": Input will be received even when not in focus or foreground.
4746 *
4747 * This hint can be set anytime.
4748 *
4749 * \since This hint is available since SDL 3.4.4.
4750 */
4751#define SDL_HINT_WINDOWS_RAW_KEYBOARD_INPUTSINK "SDL_WINDOWS_RAW_KEYBOARD_INPUTSINK"
4752
4753/**
4754 * A variable controlling whether the RIDEV_NOLEGACY flag is set when enabling
4755 * Windows raw mouse events.
4756 *
4757 * If RIDEV_NOLEGACY is set, then Windows mouse events will not be sent for
4758 * mouse motion while relative mode is enabled. This improves performance when
4759 * players are using high DPI mice, but should be disabled while showing
4760 * custom assert dialogs in your application code.
4761 *
4762 * Caution: Windows will not see mouse button releases in relative mode with
4763 * this active. This means you should not enable relative mode while a mouse
4764 * button is currently pressed.
4765 *
4766 * - "0": Windows mouse events will be generated while relative motion is
4767 * enabled. (default)
4768 * - "1": Windows mouse events will not be generated while relative motion is
4769 * enabled.
4770 *
4771 * This hint can be set anytime.
4772 *
4773 * \since This hint is available since SDL 3.6.0.
4774 */
4775#define SDL_HINT_WINDOWS_RAW_MOUSE_NOLEGACY "SDL_WINDOWS_RAW_MOUSE_NOLEGACY"
4776
4777/**
4778 * A variable controlling whether SDL uses Kernel Semaphores on Windows.
4779 *
4780 * Kernel Semaphores are inter-process and require a context switch on every
4781 * interaction. On Windows 8 and newer, the WaitOnAddress API is available.
4782 * Using that and atomics to implement semaphores increases performance. SDL
4783 * will fall back to Kernel Objects on older OS versions or if forced to by
4784 * this hint.
4785 *
4786 * The variable can be set to the following values:
4787 *
4788 * - "0": Use Atomics and WaitOnAddress API when available, otherwise fall
4789 * back to Kernel Objects. (default)
4790 * - "1": Force the use of Kernel Objects in all cases.
4791 *
4792 * This hint should be set before SDL is initialized.
4793 *
4794 * \since This hint is available since SDL 3.2.0.
4795 */
4796#define SDL_HINT_WINDOWS_FORCE_SEMAPHORE_KERNEL "SDL_WINDOWS_FORCE_SEMAPHORE_KERNEL"
4797
4798/**
4799 * A variable to specify custom icon resource id from RC file on Windows
4800 * platform.
4801 *
4802 * This hint should be set before SDL is initialized.
4803 *
4804 * \since This hint is available since SDL 3.2.0.
4805 */
4806#define SDL_HINT_WINDOWS_INTRESOURCE_ICON "SDL_WINDOWS_INTRESOURCE_ICON"
4807
4808/**
4809 * A variable to specify custom icon resource id from RC file on Windows
4810 * platform.
4811 *
4812 * This hint should be set before SDL is initialized.
4813 *
4814 * \since This hint is available since SDL 3.2.0.
4815 */
4816#define SDL_HINT_WINDOWS_INTRESOURCE_ICON_SMALL "SDL_WINDOWS_INTRESOURCE_ICON_SMALL"
4817
4818/**
4819 * A variable controlling whether SDL uses the D3D9Ex API introduced in
4820 * Windows Vista, instead of normal D3D9.
4821 *
4822 * Direct3D 9Ex contains changes to state management that can eliminate device
4823 * loss errors during scenarios like Alt+Tab or UAC prompts. D3D9Ex may
4824 * require some changes to your application to cope with the new behavior, so
4825 * this is disabled by default.
4826 *
4827 * For more information on Direct3D 9Ex, see:
4828 *
4829 * - https://docs.microsoft.com/en-us/windows/win32/direct3darticles/graphics-apis-in-windows-vista#direct3d-9ex
4830 * - https://docs.microsoft.com/en-us/windows/win32/direct3darticles/direct3d-9ex-improvements
4831 *
4832 * The variable can be set to the following values:
4833 *
4834 * - "0": Use the original Direct3D 9 API. (default)
4835 * - "1": Use the Direct3D 9Ex API on Vista and later (and fall back if D3D9Ex
4836 * is unavailable)
4837 *
4838 * This hint should be set before SDL is initialized.
4839 *
4840 * \since This hint is available since SDL 3.2.0.
4841 */
4842#define SDL_HINT_WINDOWS_USE_D3D9EX "SDL_WINDOWS_USE_D3D9EX"
4843
4844/**
4845 * A variable controlling whether SDL will clear the window contents when the
4846 * WM_ERASEBKGND message is received.
4847 *
4848 * The variable can be set to the following values:
4849 *
4850 * - "0"/"never": Never clear the window.
4851 * - "1"/"initial": Clear the window when the first WM_ERASEBKGND event fires.
4852 * (default)
4853 * - "2"/"always": Clear the window on every WM_ERASEBKGND event.
4854 *
4855 * This hint should be set before creating a window.
4856 *
4857 * \since This hint is available since SDL 3.2.0.
4858 */
4859#define SDL_HINT_WINDOWS_ERASE_BACKGROUND_MODE "SDL_WINDOWS_ERASE_BACKGROUND_MODE"
4860
4861/**
4862 * A variable controlling whether X11 windows are marked as override-redirect.
4863 *
4864 * If set, this _might_ increase framerate at the expense of the desktop not
4865 * working as expected. Override-redirect windows aren't noticed by the window
4866 * manager at all.
4867 *
4868 * You should probably only use this for fullscreen windows, and you probably
4869 * shouldn't even use it for that. But it's here if you want to try!
4870 *
4871 * The variable can be set to the following values:
4872 *
4873 * - "0": Do not mark the window as override-redirect. (default)
4874 * - "1": Mark the window as override-redirect.
4875 *
4876 * This hint should be set before creating a window.
4877 *
4878 * \since This hint is available since SDL 3.2.0.
4879 */
4880#define SDL_HINT_X11_FORCE_OVERRIDE_REDIRECT "SDL_X11_FORCE_OVERRIDE_REDIRECT"
4881
4882/**
4883 * A variable specifying the type of an X11 window.
4884 *
4885 * During SDL_CreateWindow, SDL uses the _NET_WM_WINDOW_TYPE X11 property to
4886 * report to the window manager the type of window it wants to create. This
4887 * might be set to various things if SDL_WINDOW_TOOLTIP or
4888 * SDL_WINDOW_POPUP_MENU, etc, were specified. For "normal" windows that
4889 * haven't set a specific type, this hint can be used to specify a custom
4890 * type. For example, a dock window might set this to
4891 * "_NET_WM_WINDOW_TYPE_DOCK".
4892 *
4893 * This hint should be set before creating a window.
4894 *
4895 * \since This hint is available since SDL 3.2.0.
4896 */
4897#define SDL_HINT_X11_WINDOW_TYPE "SDL_X11_WINDOW_TYPE"
4898
4899/**
4900 * Specify the XCB library to load for the X11 driver.
4901 *
4902 * The default is platform-specific, often "libX11-xcb.so.1".
4903 *
4904 * This hint should be set before initializing the video subsystem.
4905 *
4906 * \since This hint is available since SDL 3.2.0.
4907 */
4908#define SDL_HINT_X11_XCB_LIBRARY "SDL_X11_XCB_LIBRARY"
4909
4910/**
4911 * A variable controlling whether XInput should be used for controller
4912 * handling.
4913 *
4914 * The variable can be set to the following values:
4915 *
4916 * - "0": XInput is not enabled.
4917 * - "1": XInput is enabled. (default)
4918 *
4919 * This hint should be set before SDL is initialized.
4920 *
4921 * \since This hint is available since SDL 3.2.0.
4922 */
4923#define SDL_HINT_XINPUT_ENABLED "SDL_XINPUT_ENABLED"
4924
4925/**
4926 * A variable controlling response to SDL_assert failures.
4927 *
4928 * The variable can be set to the following case-sensitive values:
4929 *
4930 * - "abort": Program terminates immediately.
4931 * - "break": Program triggers a debugger breakpoint.
4932 * - "retry": Program reruns the SDL_assert's test again.
4933 * - "ignore": Program continues on, ignoring this assertion failure this
4934 * time.
4935 * - "always_ignore": Program continues on, ignoring this assertion failure
4936 * for the rest of the run.
4937 *
4938 * Note that SDL_SetAssertionHandler offers a programmatic means to deal with
4939 * assertion failures through a callback, and this hint is largely intended to
4940 * be used via environment variables by end users and automated tools.
4941 *
4942 * This hint should be set before an assertion failure is triggered and can be
4943 * changed at any time.
4944 *
4945 * \since This hint is available since SDL 3.2.0.
4946 */
4947#define SDL_HINT_ASSERT "SDL_ASSERT"
4948
4949/**
4950 * A variable controlling whether pen events should generate synthetic mouse
4951 * events.
4952 *
4953 * The variable can be set to the following values:
4954 *
4955 * - "0": Pen events will not generate mouse events.
4956 * - "1": Pen events will generate mouse events. (default)
4957 *
4958 * This hint can be set anytime.
4959 *
4960 * \since This hint is available since SDL 3.2.0.
4961 */
4962#define SDL_HINT_PEN_MOUSE_EVENTS "SDL_PEN_MOUSE_EVENTS"
4963
4964/**
4965 * A variable controlling whether pen events should generate synthetic touch
4966 * events.
4967 *
4968 * The variable can be set to the following values:
4969 *
4970 * - "0": Pen events will not generate touch events.
4971 * - "1": Pen events will generate touch events. (default)
4972 *
4973 * This hint can be set anytime.
4974 *
4975 * \since This hint is available since SDL 3.2.0.
4976 */
4977#define SDL_HINT_PEN_TOUCH_EVENTS "SDL_PEN_TOUCH_EVENTS"
4978
4979/**
4980 * An enumeration of hint priorities.
4981 *
4982 * \since This enum is available since SDL 3.2.0.
4983 */
4990
4991/**
4992 * Set a hint with a specific priority.
4993 *
4994 * The priority controls the behavior when setting a hint that already has a
4995 * value. Hints will replace existing hints of their priority and lower.
4996 * Environment variables are considered to have override priority.
4997 *
4998 * \param name the hint to set.
4999 * \param value the value of the hint variable.
5000 * \param priority the SDL_HintPriority level for the hint.
5001 * \returns true on success or false on failure; call SDL_GetError() for more
5002 * information.
5003 *
5004 * \threadsafety It is safe to call this function from any thread.
5005 *
5006 * \since This function is available since SDL 3.2.0.
5007 *
5008 * \sa SDL_GetHint
5009 * \sa SDL_ResetHint
5010 * \sa SDL_SetHint
5011 */
5012extern SDL_DECLSPEC bool SDLCALL SDL_SetHintWithPriority(const char *name, const char *value, SDL_HintPriority priority);
5013
5014/**
5015 * Set a hint with normal priority.
5016 *
5017 * Hints will not be set if there is an existing override hint or environment
5018 * variable that takes precedence. You can use SDL_SetHintWithPriority() to
5019 * set the hint with override priority instead.
5020 *
5021 * \param name the hint to set.
5022 * \param value the value of the hint variable.
5023 * \returns true on success or false on failure; call SDL_GetError() for more
5024 * information.
5025 *
5026 * \threadsafety It is safe to call this function from any thread.
5027 *
5028 * \since This function is available since SDL 3.2.0.
5029 *
5030 * \sa SDL_GetHint
5031 * \sa SDL_ResetHint
5032 * \sa SDL_SetHintWithPriority
5033 */
5034extern SDL_DECLSPEC bool SDLCALL SDL_SetHint(const char *name, const char *value);
5035
5036/**
5037 * Reset a hint to the default value.
5038 *
5039 * This will reset a hint to the value of the environment variable, or NULL if
5040 * the environment isn't set. Callbacks will be called normally with this
5041 * change.
5042 *
5043 * \param name the hint to set.
5044 * \returns true on success or false on failure; call SDL_GetError() for more
5045 * information.
5046 *
5047 * \threadsafety It is safe to call this function from any thread.
5048 *
5049 * \since This function is available since SDL 3.2.0.
5050 *
5051 * \sa SDL_SetHint
5052 * \sa SDL_ResetHints
5053 */
5054extern SDL_DECLSPEC bool SDLCALL SDL_ResetHint(const char *name);
5055
5056/**
5057 * Reset all hints to the default values.
5058 *
5059 * This will reset all hints to the value of the associated environment
5060 * variable, or NULL if the environment isn't set. Callbacks will be called
5061 * normally with this change.
5062 *
5063 * \threadsafety It is safe to call this function from any thread.
5064 *
5065 * \since This function is available since SDL 3.2.0.
5066 *
5067 * \sa SDL_ResetHint
5068 */
5069extern SDL_DECLSPEC void SDLCALL SDL_ResetHints(void);
5070
5071/**
5072 * Get the value of a hint.
5073 *
5074 * \param name the hint to query.
5075 * \returns the string value of a hint or NULL if the hint isn't set.
5076 *
5077 * \threadsafety It is safe to call this function from any thread.
5078 *
5079 * \since This function is available since SDL 3.2.0.
5080 *
5081 * \sa SDL_SetHint
5082 * \sa SDL_SetHintWithPriority
5083 */
5084extern SDL_DECLSPEC const char *SDLCALL SDL_GetHint(const char *name);
5085
5086/**
5087 * Get the boolean value of a hint variable.
5088 *
5089 * \param name the name of the hint to get the boolean value from.
5090 * \param default_value the value to return if the hint does not exist.
5091 * \returns the boolean value of a hint or the provided default value if the
5092 * hint does not exist.
5093 *
5094 * \threadsafety It is safe to call this function from any thread.
5095 *
5096 * \since This function is available since SDL 3.2.0.
5097 *
5098 * \sa SDL_GetHint
5099 * \sa SDL_SetHint
5100 */
5101extern SDL_DECLSPEC bool SDLCALL SDL_GetHintBoolean(const char *name, bool default_value);
5102
5103/**
5104 * A callback used to send notifications of hint value changes.
5105 *
5106 * This is called an initial time during SDL_AddHintCallback with the hint's
5107 * current value, and then again each time the hint's value changes. In the
5108 * initial call, the current value is in both `oldValue` and `newValue`.
5109 *
5110 * \param userdata what was passed as `userdata` to SDL_AddHintCallback().
5111 * \param name what was passed as `name` to SDL_AddHintCallback().
5112 * \param oldValue the previous hint value.
5113 * \param newValue the new value hint is to be set to.
5114 *
5115 * \threadsafety This callback is fired from whatever thread is setting a new
5116 * hint value. SDL holds a lock on the hint subsystem when
5117 * calling this callback.
5118 *
5119 * \since This datatype is available since SDL 3.2.0.
5120 *
5121 * \sa SDL_AddHintCallback
5122 */
5123typedef void(SDLCALL *SDL_HintCallback)(void *userdata, const char *name, const char *oldValue, const char *newValue);
5124
5125/**
5126 * Add a function to watch a particular hint.
5127 *
5128 * The callback function is called _during_ this function, to provide it an
5129 * initial value, and again each time the hint's value changes.
5130 *
5131 * \param name the hint to watch.
5132 * \param callback An SDL_HintCallback function that will be called when the
5133 * hint value changes.
5134 * \param userdata a pointer to pass to the callback function.
5135 * \returns true on success or false on failure; call SDL_GetError() for more
5136 * information.
5137 *
5138 * \threadsafety It is safe to call this function from any thread.
5139 *
5140 * \since This function is available since SDL 3.2.0.
5141 *
5142 * \sa SDL_RemoveHintCallback
5143 */
5144extern SDL_DECLSPEC bool SDLCALL SDL_AddHintCallback(const char *name, SDL_HintCallback callback, void *userdata);
5145
5146/**
5147 * Remove a function watching a particular hint.
5148 *
5149 * \param name the hint being watched.
5150 * \param callback an SDL_HintCallback function that will be called when the
5151 * hint value changes.
5152 * \param userdata a pointer being passed to the callback function.
5153 *
5154 * \threadsafety It is safe to call this function from any thread.
5155 *
5156 * \since This function is available since SDL 3.2.0.
5157 *
5158 * \sa SDL_AddHintCallback
5159 */
5160extern SDL_DECLSPEC void SDLCALL SDL_RemoveHintCallback(const char *name,
5161 SDL_HintCallback callback,
5162 void *userdata);
5163
5164/* Ends C function definitions when using C++ */
5165#ifdef __cplusplus
5166}
5167#endif
5168#include <SDL3/SDL_close_code.h>
5169
5170#endif /* SDL_hints_h_ */
bool SDL_ResetHint(const char *name)
void SDL_RemoveHintCallback(const char *name, SDL_HintCallback callback, void *userdata)
void SDL_ResetHints(void)
bool SDL_GetHintBoolean(const char *name, bool default_value)
bool SDL_SetHintWithPriority(const char *name, const char *value, SDL_HintPriority priority)
bool SDL_SetHint(const char *name, const char *value)
SDL_HintPriority
Definition SDL_hints.h:4985
@ SDL_HINT_DEFAULT
Definition SDL_hints.h:4986
@ SDL_HINT_OVERRIDE
Definition SDL_hints.h:4988
@ SDL_HINT_NORMAL
Definition SDL_hints.h:4987
const char * SDL_GetHint(const char *name)
bool SDL_AddHintCallback(const char *name, SDL_HintCallback callback, void *userdata)
void(* SDL_HintCallback)(void *userdata, const char *name, const char *oldValue, const char *newValue)
Definition SDL_hints.h:5123