SDL_hints.h 162 KB

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