SDL_migration.cocci 41 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499
  1. //
  2. // This is a coccinelle semantic patch to ease migration of your project from SDL2 to SDL3.
  3. //
  4. // It generates a patch that you can apply to your project to build for SDL3. It does not
  5. // handle conceptual API changes, but it automates API name changes and function parameter
  6. // transformations.
  7. //
  8. // To install (native Ubuntu or using WSL on Windows):
  9. // sudo apt install coccinelle
  10. //
  11. // Apply the semantic patch to generate a patch file:
  12. // cd path/to/your/code
  13. // spatch --sp-file path/to/SDL_migration.cocci . >patch.txt
  14. //
  15. // A few options:
  16. // --c++=11 to parse cpp file
  17. // --max-width 200 to increase line witdth of generated source
  18. //
  19. // Apply the patch to your project:
  20. // patch -p1 <patch.txt
  21. //
  22. //
  23. // #############
  24. // In very short, a semantic patch is composed of two sub-blocks, like
  25. //
  26. // @@
  27. // declaration
  28. // @@
  29. // rule / transformation
  30. //
  31. // So this file is a set of many semantic patches, mostly independant.
  32. @ rule_audio_open @
  33. expression e1, e2;
  34. @@
  35. - SDL_OpenAudio(e1, e2)
  36. + (g_audio_id = SDL_OpenAudioDevice(NULL, 0, e1, e2, 0)) > 0 ? 0 : -1
  37. @ depends on rule_audio_open @
  38. @@
  39. {
  40. + /* FIXME MIGRATION: maybe move this to a global scope ? */
  41. + SDL_AudioDeviceID g_audio_id = -1;
  42. ...
  43. SDL_OpenAudioDevice(...)
  44. ...
  45. }
  46. @@
  47. @@
  48. - SDL_LockAudio()
  49. + SDL_LockAudioDevice(g_audio_id)
  50. @@
  51. @@
  52. - SDL_UnlockAudio()
  53. + SDL_UnlockAudioDevice(g_audio_id)
  54. @@
  55. @@
  56. - SDL_CloseAudio(void)
  57. + SDL_CloseAudioDevice(g_audio_id)
  58. @@
  59. expression e;
  60. @@
  61. - SDL_PauseAudio(e)
  62. + e == SDL_TRUE ? SDL_PauseAudioDevice(g_audio_id) : SDL_PlayAudioDevice(g_audio_id)
  63. @@
  64. @@
  65. - SDL_GetAudioStatus()
  66. + SDL_GetAudioDeviceStatus(g_audio_id)
  67. @@
  68. @@
  69. - SDL_GetQueuedAudioSize(1)
  70. + SDL_GetQueuedAudioSize(g_audio_id)
  71. @@
  72. expression e1, e2;
  73. @@
  74. - SDL_QueueAudio(1, e1, e2)
  75. + SDL_QueueAudio(g_audio_id, e1, e2)
  76. // SDL_EventState() - replaced with SDL_SetEventEnabled()
  77. @@
  78. expression e1;
  79. @@
  80. (
  81. - SDL_EventState(e1, SDL_IGNORE)
  82. + SDL_SetEventEnabled(e1, SDL_FALSE)
  83. |
  84. - SDL_EventState(e1, SDL_DISABLE)
  85. + SDL_SetEventEnabled(e1, SDL_FALSE)
  86. |
  87. - SDL_EventState(e1, SDL_ENABLE)
  88. + SDL_SetEventEnabled(e1, SDL_TRUE)
  89. |
  90. - SDL_EventState(e1, SDL_QUERY)
  91. + SDL_EventEnabled(e1)
  92. )
  93. // SDL_GetEventState() - replaced with SDL_EventEnabled()
  94. @@
  95. expression e1;
  96. @@
  97. - SDL_GetEventState(e1)
  98. + SDL_EventEnabled(e1)
  99. @@
  100. expression e;
  101. @@
  102. - SDL_JoystickGetDevicePlayerIndex(e)
  103. + /* FIXME MIGRATION: check for valid instance */
  104. + SDL_GetJoystickInstancePlayerIndex(GetJoystickInstanceFromIndex(e))
  105. @@
  106. expression e;
  107. @@
  108. - SDL_JoystickIsVirtual(e)
  109. + /* FIXME MIGRATION: check for valid instance */
  110. + SDL_IsJoystickVirtual(GetJoystickInstanceFromIndex(e))
  111. @@
  112. expression e;
  113. @@
  114. - SDL_JoystickPathForIndex(e)
  115. + /* FIXME MIGRATION: check for valid instance */
  116. + SDL_GetJoystickInstancePath(GetJoystickInstanceFromIndex(e))
  117. @@
  118. expression e;
  119. @@
  120. - SDL_IsGameController(e)
  121. + /* FIXME MIGRATION: check for valid instance */
  122. + SDL_IsGamepad(GetJoystickInstanceFromIndex(e))
  123. @@
  124. expression e;
  125. @@
  126. - SDL_GameControllerMappingForDeviceIndex(e)
  127. + /* FIXME MIGRATION: check for valid instance */
  128. + SDL_GetGamepadInstanceMapping(GetJoystickInstanceFromIndex(e))
  129. @@
  130. expression e;
  131. @@
  132. - SDL_GameControllerNameForIndex(e)
  133. + /* FIXME MIGRATION: check for valid instance */
  134. + SDL_GetGamepadInstanceName(GetJoystickInstanceFromIndex(e))
  135. @@
  136. expression e;
  137. @@
  138. - SDL_GameControllerPathForIndex(e)
  139. + /* FIXME MIGRATION: check for valid instance */
  140. + SDL_GetGamepadInstancePath(GetJoystickInstanceFromIndex(e))
  141. @@
  142. expression e;
  143. @@
  144. - SDL_GameControllerTypeForIndex(e)
  145. + /* FIXME MIGRATION: check for valid instance */
  146. + SDL_GetGamepadInstanceType(GetJoystickInstanceFromIndex(e))
  147. // SDL_Has3DNow() has been removed; there is no replacement.
  148. @@
  149. @@
  150. + /* FIXME MIGRATION: SDL_Has3DNow() has been removed; there is no replacement. */ 0
  151. - SDL_Has3DNow()
  152. // SDL_HINT_VIDEO_X11_XINERAMA (Xinerama no longer supported by the X11 backend)
  153. @@
  154. @@
  155. + /* FIXME MIGRATION: no longer support by the X11 backend */ NULL
  156. - SDL_HINT_VIDEO_X11_XINERAMA
  157. // SDL_HINT_VIDEO_X11_XVIDMODE (Xvidmode no longer supported by the X11 backend)
  158. @@
  159. @@
  160. + /* FIXME MIGRATION: no longer support by the X11 backend */ NULL
  161. - SDL_HINT_VIDEO_X11_XVIDMODE
  162. // SDL_HINT_VIDEO_X11_FORCE_EGL (use SDL_HINT_VIDEO_FORCE_EGL instead)
  163. @@
  164. @@
  165. - SDL_HINT_VIDEO_X11_FORCE_EGL
  166. + SDL_HINT_VIDEO_FORCE_EGL
  167. @@
  168. @@
  169. - SDL_HINT_AUDIODRIVER
  170. + SDL_HINT_AUDIO_DRIVER
  171. @@
  172. @@
  173. - SDL_HINT_VIDEODRIVER
  174. + SDL_HINT_VIDEO_DRIVER
  175. @@
  176. @@
  177. - M_PI
  178. + SDL_PI_D
  179. // SDL_GetRevisionNumber() has been removed from the API, it always returned 0 in SDL 2.0.
  180. @@
  181. @@
  182. + /* FIXME MIGRATION: SDL_GetRevisionNumber() removed */ 0
  183. - SDL_GetRevisionNumber()
  184. // SDL_RWread
  185. @ rule_rwread @
  186. expression e1, e2, e3, e4;
  187. identifier i;
  188. @@
  189. (
  190. i = SDL_RWread(e1, e2,
  191. - e3, e4);
  192. + e3 * e4);
  193. + i = (i <= 0) ? 0 : i / e3;
  194. |
  195. SDL_RWread(e1, e2,
  196. - e3, e4);
  197. + e3 * e4);
  198. |
  199. + /* FIXME MIGRATION: double-check if you use the returned value of SDL_RWread() */
  200. SDL_RWread(e1, e2,
  201. - e3, e4)
  202. + e3 * e4)
  203. )
  204. // SDL_RWwrite
  205. @ rule_rwwrite @
  206. expression e1, e2, e3, e4;
  207. identifier i;
  208. @@
  209. (
  210. i = SDL_RWwrite(e1, e2,
  211. - e3, e4);
  212. + e3 * e4);
  213. + i = (i <= 0) ? 0 : i / e3;
  214. |
  215. SDL_RWwrite(e1, e2,
  216. - e3, e4);
  217. + e3 * e4);
  218. |
  219. + /* FIXME MIGRATION: double-check if you use the returned value of SDL_RWwrite() */
  220. SDL_RWwrite(e1, e2,
  221. - e3, e4)
  222. + e3 * e4)
  223. )
  224. @ depends on rule_rwread || rule_rwwrite @
  225. expression e;
  226. @@
  227. (
  228. - e * 1
  229. + e
  230. |
  231. - e / 1
  232. + e
  233. )
  234. // SDL_SIMDAlloc(), SDL_SIMDFree() have been removed.
  235. @@
  236. expression e1;
  237. @@
  238. - SDL_SIMDAlloc(e1)
  239. + SDL_aligned_alloc(SDL_SIMDGetAlignment(), e1)
  240. @@
  241. expression e1;
  242. @@
  243. - SDL_SIMDFree(
  244. + SDL_aligned_free(
  245. e1)
  246. // SDL_Vulkan_GetInstanceExtensions() no longer takes a window parameter.
  247. @@
  248. expression e1, e2, e3;
  249. @@
  250. SDL_Vulkan_GetInstanceExtensions(
  251. - e1,
  252. e2, e3)
  253. // SDL_Vulkan_GetVkGetInstanceProcAddr() now returns `SDL_FunctionPointer` instead of `void *`, and should be cast to PFN_vkGetInstanceProcAddr.
  254. @@
  255. typedef PFN_vkGetInstanceProcAddr;
  256. @@
  257. (
  258. (PFN_vkGetInstanceProcAddr)SDL_Vulkan_GetVkGetInstanceProcAddr()
  259. |
  260. + (PFN_vkGetInstanceProcAddr)
  261. SDL_Vulkan_GetVkGetInstanceProcAddr()
  262. )
  263. // SDL_PauseAudioDevice / SDL_PlayAudioDevice
  264. @@
  265. expression e;
  266. @@
  267. (
  268. - SDL_PauseAudioDevice(e, 1)
  269. + SDL_PauseAudioDevice(e)
  270. |
  271. - SDL_PauseAudioDevice(e, SDL_TRUE)
  272. + SDL_PauseAudioDevice(e)
  273. |
  274. - SDL_PauseAudioDevice(e, 0)
  275. + SDL_PlayAudioDevice(e)
  276. |
  277. - SDL_PauseAudioDevice(e, SDL_FALSE)
  278. + SDL_PlayAudioDevice(e)
  279. )
  280. @@
  281. expression e, pause_on;
  282. @@
  283. - SDL_PauseAudioDevice(e, pause_on);
  284. + if (pause_on) {
  285. + SDL_PauseAudioDevice(e);
  286. + } else {
  287. + SDL_PlayAudioDevice(e);
  288. + }
  289. // Remove SDL_WINDOW_SHOWN
  290. @@
  291. expression e;
  292. @@
  293. (
  294. - SDL_WINDOW_SHOWN | e
  295. + e
  296. |
  297. - SDL_WINDOW_SHOWN
  298. + 0
  299. )
  300. @@
  301. // Remove parameter from SDL_ConvertSurface
  302. expression e1, e2, e3;
  303. @@
  304. SDL_ConvertSurface(e1, e2
  305. - ,e3)
  306. + )
  307. @@
  308. // Remove parameter from SDL_ConvertSurfaceFormat
  309. expression e1, e2, e3;
  310. @@
  311. SDL_ConvertSurfaceFormat(e1, e2
  312. - ,e3)
  313. + )
  314. @@
  315. // SDL_CreateRGBSurfaceWithFormat
  316. // remove 'flags'
  317. // remove 'depth'
  318. // rename to SDL_CreateSurface
  319. expression e1, e2, e3, e4, e5;
  320. @@
  321. - SDL_CreateRGBSurfaceWithFormat(e1, e2, e3, e4, e5)
  322. + SDL_CreateSurface(e2, e3, e5)
  323. @@
  324. // SDL_CreateRGBSurfaceWithFormat:
  325. // remove 'depth'
  326. // rename to SDL_CreateSurfaceFrom
  327. expression e1, e2, e3, e4, e5, e6;
  328. @@
  329. - SDL_CreateRGBSurfaceWithFormatFrom(e1, e2, e3, e4, e5, e6)
  330. + SDL_CreateSurfaceFrom(e1, e2, e3, e5, e6)
  331. @@
  332. // SDL_CreateRGBSurface : convert Masks to format
  333. expression e1, e2, e3, e4, e5, e6, e7, e8, e9;
  334. @@
  335. (
  336. // Generated for all formats:
  337. - SDL_CreateRGBSurface(e1, e2, e3, 1, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  338. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_INDEX1LSB)
  339. |
  340. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 1, e4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  341. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_INDEX1LSB)
  342. |
  343. - SDL_CreateRGBSurface(e1, e2, e3, 1, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  344. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_INDEX1MSB)
  345. |
  346. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 1, e4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  347. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_INDEX1MSB)
  348. |
  349. - SDL_CreateRGBSurface(e1, e2, e3, 4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  350. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_INDEX4LSB)
  351. |
  352. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 4, e4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  353. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_INDEX4LSB)
  354. |
  355. - SDL_CreateRGBSurface(e1, e2, e3, 4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  356. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_INDEX4MSB)
  357. |
  358. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 4, e4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  359. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_INDEX4MSB)
  360. |
  361. - SDL_CreateRGBSurface(e1, e2, e3, 8, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  362. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_INDEX8)
  363. |
  364. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 8, e4, 0x00000000, 0x00000000, 0x00000000, 0x00000000)
  365. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_INDEX8)
  366. |
  367. - SDL_CreateRGBSurface(e1, e2, e3, 8, 0x000000E0, 0x0000001C, 0x00000003, 0x00000000)
  368. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB332)
  369. |
  370. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 8, e4, 0x000000E0, 0x0000001C, 0x00000003, 0x00000000)
  371. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB332)
  372. |
  373. - SDL_CreateRGBSurface(e1, e2, e3, 12, 0x00000F00, 0x000000F0, 0x0000000F, 0x00000000)
  374. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB444)
  375. |
  376. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 12, e4, 0x00000F00, 0x000000F0, 0x0000000F, 0x00000000)
  377. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB444)
  378. |
  379. - SDL_CreateRGBSurface(e1, e2, e3, 15, 0x00007C00, 0x000003E0, 0x0000001F, 0x00000000)
  380. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB555)
  381. |
  382. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 15, e4, 0x00007C00, 0x000003E0, 0x0000001F, 0x00000000)
  383. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB555)
  384. |
  385. - SDL_CreateRGBSurface(e1, e2, e3, 15, 0x0000001F, 0x000003E0, 0x00007C00, 0x00000000)
  386. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGR555)
  387. |
  388. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 15, e4, 0x0000001F, 0x000003E0, 0x00007C00, 0x00000000)
  389. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGR555)
  390. |
  391. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x00000F00, 0x000000F0, 0x0000000F, 0x0000F000)
  392. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ARGB4444)
  393. |
  394. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x00000F00, 0x000000F0, 0x0000000F, 0x0000F000)
  395. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ARGB4444)
  396. |
  397. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000F000, 0x00000F00, 0x000000F0, 0x0000000F)
  398. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGBA4444)
  399. |
  400. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000F000, 0x00000F00, 0x000000F0, 0x0000000F)
  401. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGBA4444)
  402. |
  403. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000000F, 0x000000F0, 0x00000F00, 0x0000F000)
  404. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ABGR4444)
  405. |
  406. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000000F, 0x000000F0, 0x00000F00, 0x0000F000)
  407. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ABGR4444)
  408. |
  409. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x000000F0, 0x00000F00, 0x0000F000, 0x0000000F)
  410. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGRA4444)
  411. |
  412. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x000000F0, 0x00000F00, 0x0000F000, 0x0000000F)
  413. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGRA4444)
  414. |
  415. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x00007C00, 0x000003E0, 0x0000001F, 0x00008000)
  416. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ARGB1555)
  417. |
  418. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x00007C00, 0x000003E0, 0x0000001F, 0x00008000)
  419. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ARGB1555)
  420. |
  421. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000F800, 0x000007C0, 0x0000003E, 0x00000001)
  422. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGBA5551)
  423. |
  424. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000F800, 0x000007C0, 0x0000003E, 0x00000001)
  425. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGBA5551)
  426. |
  427. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000001F, 0x000003E0, 0x00007C00, 0x00008000)
  428. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ABGR1555)
  429. |
  430. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000001F, 0x000003E0, 0x00007C00, 0x00008000)
  431. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ABGR1555)
  432. |
  433. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000003E, 0x000007C0, 0x0000F800, 0x00000001)
  434. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGRA5551)
  435. |
  436. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000003E, 0x000007C0, 0x0000F800, 0x00000001)
  437. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGRA5551)
  438. |
  439. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000F800, 0x000007E0, 0x0000001F, 0x00000000)
  440. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB565)
  441. |
  442. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000F800, 0x000007E0, 0x0000001F, 0x00000000)
  443. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB565)
  444. |
  445. - SDL_CreateRGBSurface(e1, e2, e3, 16, 0x0000001F, 0x000007E0, 0x0000F800, 0x00000000)
  446. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGR565)
  447. |
  448. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 16, e4, 0x0000001F, 0x000007E0, 0x0000F800, 0x00000000)
  449. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGR565)
  450. |
  451. - SDL_CreateRGBSurface(e1, e2, e3, 24, 0x000000FF, 0x0000FF00, 0x00FF0000, 0x00000000)
  452. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB24)
  453. |
  454. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 24, e4, 0x000000FF, 0x0000FF00, 0x00FF0000, 0x00000000)
  455. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB24)
  456. |
  457. - SDL_CreateRGBSurface(e1, e2, e3, 24, 0x00FF0000, 0x0000FF00, 0x000000FF, 0x00000000)
  458. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGR24)
  459. |
  460. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 24, e4, 0x00FF0000, 0x0000FF00, 0x000000FF, 0x00000000)
  461. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGR24)
  462. |
  463. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x00FF0000, 0x0000FF00, 0x000000FF, 0x00000000)
  464. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGB888)
  465. |
  466. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x00FF0000, 0x0000FF00, 0x000000FF, 0x00000000)
  467. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGB888)
  468. |
  469. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0xFF000000, 0x00FF0000, 0x0000FF00, 0x00000000)
  470. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGBX8888)
  471. |
  472. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0xFF000000, 0x00FF0000, 0x0000FF00, 0x00000000)
  473. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGBX8888)
  474. |
  475. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x000000FF, 0x0000FF00, 0x00FF0000, 0x00000000)
  476. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGR888)
  477. |
  478. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x000000FF, 0x0000FF00, 0x00FF0000, 0x00000000)
  479. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGR888)
  480. |
  481. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x0000FF00, 0x00FF0000, 0xFF000000, 0x00000000)
  482. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGRX8888)
  483. |
  484. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x0000FF00, 0x00FF0000, 0xFF000000, 0x00000000)
  485. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGRX8888)
  486. |
  487. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x00FF0000, 0x0000FF00, 0x000000FF, 0xFF000000)
  488. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ARGB8888)
  489. |
  490. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x00FF0000, 0x0000FF00, 0x000000FF, 0xFF000000)
  491. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ARGB8888)
  492. |
  493. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0xFF000000, 0x00FF0000, 0x0000FF00, 0x000000FF)
  494. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_RGBA8888)
  495. |
  496. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0xFF000000, 0x00FF0000, 0x0000FF00, 0x000000FF)
  497. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_RGBA8888)
  498. |
  499. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x000000FF, 0x0000FF00, 0x00FF0000, 0xFF000000)
  500. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ABGR8888)
  501. |
  502. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x000000FF, 0x0000FF00, 0x00FF0000, 0xFF000000)
  503. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ABGR8888)
  504. |
  505. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x0000FF00, 0x00FF0000, 0xFF000000, 0x000000FF)
  506. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_BGRA8888)
  507. |
  508. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x0000FF00, 0x00FF0000, 0xFF000000, 0x000000FF)
  509. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_BGRA8888)
  510. |
  511. - SDL_CreateRGBSurface(e1, e2, e3, 32, 0x3FF00000, 0x000FFC00, 0x000003FF, 0xC0000000)
  512. + SDL_CreateSurface(e2, e3, SDL_PIXELFORMAT_ARGB2101010)
  513. |
  514. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, 32, e4, 0x3FF00000, 0x000FFC00, 0x000003FF, 0xC0000000)
  515. + SDL_CreateSurfaceFrom(e1, e2, e3, e4, SDL_PIXELFORMAT_ARGB2101010)
  516. |
  517. // End Generated
  518. - SDL_CreateRGBSurface(e1, e2, e3, e4->BitsPerPixel, e4->Rmask, e4->Gmask, e4->Bmask, e4->Amask)
  519. + SDL_CreateSurface(e2, e3, e4->format)
  520. |
  521. - SDL_CreateRGBSurfaceFrom(e1, e2, e3, e4->BitsPerPixel, e5, e4->Rmask, e4->Gmask, e4->Bmask, e4->Amask)
  522. + SDL_CreateSurfaceFrom(e1, e2, e3, e5, e4->format)
  523. |
  524. -SDL_CreateRGBSurface(e1, e2, e3, e4, e5, e6, e7, e8)
  525. +SDL_CreateSurface(e2, e3, SDL_MasksToPixelFormatEnum(e4, e5, e6, e7, e8))
  526. |
  527. -SDL_CreateRGBSurfaceFrom(e1, e2, e3, e4, e5, e6, e7, e8, e9)
  528. +SDL_CreateSurfaceFrom(e1, e2, e3, e5, SDL_MasksToPixelFormatEnum(e4, e6, e7, e8, e9))
  529. )
  530. @@
  531. // SDL_CreateRenderer:
  532. // 2nd argument changed from int (default=-1) to const char* (default=NULL)
  533. expression e1, e3;
  534. int e2;
  535. @@
  536. (
  537. -SDL_CreateRenderer(e1, -1, e3)
  538. +SDL_CreateRenderer(e1, NULL, e3)
  539. |
  540. -SDL_CreateRenderer(e1, e2, e3)
  541. +SDL_CreateRenderer(e1, SDL_GetRenderDriver(e2), e3)
  542. )
  543. // Renaming of SDL_oldnames.h
  544. @@
  545. @@
  546. - SDL_AudioStreamAvailable
  547. + SDL_GetAudioStreamAvailable
  548. (...)
  549. @@
  550. @@
  551. - SDL_AudioStreamClear
  552. + SDL_ClearAudioStream
  553. (...)
  554. @@
  555. @@
  556. - SDL_AudioStreamFlush
  557. + SDL_FlushAudioStream
  558. (...)
  559. @@
  560. @@
  561. - SDL_AudioStreamGet
  562. + SDL_GetAudioStreamData
  563. (...)
  564. @@
  565. @@
  566. - SDL_AudioStreamPut
  567. + SDL_PutAudioStreamData
  568. (...)
  569. @@
  570. @@
  571. - SDL_FreeAudioStream
  572. + SDL_DestroyAudioStream
  573. (...)
  574. @@
  575. @@
  576. - SDL_FreeWAV
  577. + SDL_free
  578. (...)
  579. @@
  580. @@
  581. - SDL_NewAudioStream
  582. + SDL_CreateAudioStream
  583. (...)
  584. @@
  585. @@
  586. - SDL_CONTROLLERAXISMOTION
  587. + SDL_EVENT_GAMEPAD_AXIS_MOTION
  588. @@
  589. @@
  590. - SDL_CONTROLLERBUTTONDOWN
  591. + SDL_EVENT_GAMEPAD_BUTTON_DOWN
  592. @@
  593. @@
  594. - SDL_CONTROLLERBUTTONUP
  595. + SDL_EVENT_GAMEPAD_BUTTON_UP
  596. @@
  597. @@
  598. - SDL_CONTROLLERDEVICEADDED
  599. + SDL_EVENT_GAMEPAD_ADDED
  600. @@
  601. @@
  602. - SDL_CONTROLLERDEVICEREMAPPED
  603. + SDL_EVENT_GAMEPAD_REMAPPED
  604. @@
  605. @@
  606. - SDL_CONTROLLERDEVICEREMOVED
  607. + SDL_EVENT_GAMEPAD_REMOVED
  608. @@
  609. @@
  610. - SDL_CONTROLLERSENSORUPDATE
  611. + SDL_EVENT_GAMEPAD_SENSOR_UPDATE
  612. @@
  613. @@
  614. - SDL_CONTROLLERTOUCHPADDOWN
  615. + SDL_EVENT_GAMEPAD_TOUCHPAD_DOWN
  616. @@
  617. @@
  618. - SDL_CONTROLLERTOUCHPADMOTION
  619. + SDL_EVENT_GAMEPAD_TOUCHPAD_MOTION
  620. @@
  621. @@
  622. - SDL_CONTROLLERTOUCHPADUP
  623. + SDL_EVENT_GAMEPAD_TOUCHPAD_UP
  624. @@
  625. typedef SDL_ControllerAxisEvent, SDL_GamepadAxisEvent;
  626. @@
  627. - SDL_ControllerAxisEvent
  628. + SDL_GamepadAxisEvent
  629. @@
  630. typedef SDL_ControllerButtonEvent, SDL_GamepadButtonEvent;
  631. @@
  632. - SDL_ControllerButtonEvent
  633. + SDL_GamepadButtonEvent
  634. @@
  635. typedef SDL_ControllerDeviceEvent, SDL_GamepadDeviceEvent;
  636. @@
  637. - SDL_ControllerDeviceEvent
  638. + SDL_GamepadDeviceEvent
  639. @@
  640. typedef SDL_ControllerSensorEvent, SDL_GamepadSensorEvent;
  641. @@
  642. - SDL_ControllerSensorEvent
  643. + SDL_GamepadSensorEvent
  644. @@
  645. typedef SDL_ControllerTouchpadEvent, SDL_GamepadTouchpadEvent;
  646. @@
  647. - SDL_ControllerTouchpadEvent
  648. + SDL_GamepadTouchpadEvent
  649. @@
  650. @@
  651. - SDL_CONTROLLER_AXIS_INVALID
  652. + SDL_GAMEPAD_AXIS_INVALID
  653. @@
  654. @@
  655. - SDL_CONTROLLER_AXIS_LEFTX
  656. + SDL_GAMEPAD_AXIS_LEFTX
  657. @@
  658. @@
  659. - SDL_CONTROLLER_AXIS_LEFTY
  660. + SDL_GAMEPAD_AXIS_LEFTY
  661. @@
  662. @@
  663. - SDL_CONTROLLER_AXIS_MAX
  664. + SDL_GAMEPAD_AXIS_MAX
  665. @@
  666. @@
  667. - SDL_CONTROLLER_AXIS_RIGHTX
  668. + SDL_GAMEPAD_AXIS_RIGHTX
  669. @@
  670. @@
  671. - SDL_CONTROLLER_AXIS_RIGHTY
  672. + SDL_GAMEPAD_AXIS_RIGHTY
  673. @@
  674. @@
  675. - SDL_CONTROLLER_AXIS_TRIGGERLEFT
  676. + SDL_GAMEPAD_AXIS_LEFT_TRIGGER
  677. @@
  678. @@
  679. - SDL_CONTROLLER_AXIS_TRIGGERRIGHT
  680. + SDL_GAMEPAD_AXIS_RIGHT_TRIGGER
  681. @@
  682. @@
  683. - SDL_CONTROLLER_BINDTYPE_AXIS
  684. + SDL_GAMEPAD_BINDTYPE_AXIS
  685. @@
  686. @@
  687. - SDL_CONTROLLER_BINDTYPE_BUTTON
  688. + SDL_GAMEPAD_BINDTYPE_BUTTON
  689. @@
  690. @@
  691. - SDL_CONTROLLER_BINDTYPE_HAT
  692. + SDL_GAMEPAD_BINDTYPE_HAT
  693. @@
  694. @@
  695. - SDL_CONTROLLER_BINDTYPE_NONE
  696. + SDL_GAMEPAD_BINDTYPE_NONE
  697. @@
  698. @@
  699. - SDL_CONTROLLER_BUTTON_A
  700. + SDL_GAMEPAD_BUTTON_A
  701. @@
  702. @@
  703. - SDL_CONTROLLER_BUTTON_B
  704. + SDL_GAMEPAD_BUTTON_B
  705. @@
  706. @@
  707. - SDL_CONTROLLER_BUTTON_BACK
  708. + SDL_GAMEPAD_BUTTON_BACK
  709. @@
  710. @@
  711. - SDL_CONTROLLER_BUTTON_DPAD_DOWN
  712. + SDL_GAMEPAD_BUTTON_DPAD_DOWN
  713. @@
  714. @@
  715. - SDL_CONTROLLER_BUTTON_DPAD_LEFT
  716. + SDL_GAMEPAD_BUTTON_DPAD_LEFT
  717. @@
  718. @@
  719. - SDL_CONTROLLER_BUTTON_DPAD_RIGHT
  720. + SDL_GAMEPAD_BUTTON_DPAD_RIGHT
  721. @@
  722. @@
  723. - SDL_CONTROLLER_BUTTON_DPAD_UP
  724. + SDL_GAMEPAD_BUTTON_DPAD_UP
  725. @@
  726. @@
  727. - SDL_CONTROLLER_BUTTON_GUIDE
  728. + SDL_GAMEPAD_BUTTON_GUIDE
  729. @@
  730. @@
  731. - SDL_CONTROLLER_BUTTON_INVALID
  732. + SDL_GAMEPAD_BUTTON_INVALID
  733. @@
  734. @@
  735. - SDL_CONTROLLER_BUTTON_LEFTSHOULDER
  736. + SDL_GAMEPAD_BUTTON_LEFT_SHOULDER
  737. @@
  738. @@
  739. - SDL_CONTROLLER_BUTTON_LEFTSTICK
  740. + SDL_GAMEPAD_BUTTON_LEFT_STICK
  741. @@
  742. @@
  743. - SDL_CONTROLLER_BUTTON_MAX
  744. + SDL_GAMEPAD_BUTTON_MAX
  745. @@
  746. @@
  747. - SDL_CONTROLLER_BUTTON_MISC1
  748. + SDL_GAMEPAD_BUTTON_MISC1
  749. @@
  750. @@
  751. - SDL_CONTROLLER_BUTTON_PADDLE1
  752. + SDL_GAMEPAD_BUTTON_PADDLE1
  753. @@
  754. @@
  755. - SDL_CONTROLLER_BUTTON_PADDLE2
  756. + SDL_GAMEPAD_BUTTON_PADDLE2
  757. @@
  758. @@
  759. - SDL_CONTROLLER_BUTTON_PADDLE3
  760. + SDL_GAMEPAD_BUTTON_PADDLE3
  761. @@
  762. @@
  763. - SDL_CONTROLLER_BUTTON_PADDLE4
  764. + SDL_GAMEPAD_BUTTON_PADDLE4
  765. @@
  766. @@
  767. - SDL_CONTROLLER_BUTTON_RIGHTSHOULDER
  768. + SDL_GAMEPAD_BUTTON_RIGHT_SHOULDER
  769. @@
  770. @@
  771. - SDL_CONTROLLER_BUTTON_RIGHTSTICK
  772. + SDL_GAMEPAD_BUTTON_RIGHT_STICK
  773. @@
  774. @@
  775. - SDL_CONTROLLER_BUTTON_START
  776. + SDL_GAMEPAD_BUTTON_START
  777. @@
  778. @@
  779. - SDL_CONTROLLER_BUTTON_TOUCHPAD
  780. + SDL_GAMEPAD_BUTTON_TOUCHPAD
  781. @@
  782. @@
  783. - SDL_CONTROLLER_BUTTON_X
  784. + SDL_GAMEPAD_BUTTON_X
  785. @@
  786. @@
  787. - SDL_CONTROLLER_BUTTON_Y
  788. + SDL_GAMEPAD_BUTTON_Y
  789. @@
  790. @@
  791. - SDL_CONTROLLER_TYPE_AMAZON_LUNA
  792. + SDL_GAMEPAD_TYPE_AMAZON_LUNA
  793. @@
  794. @@
  795. - SDL_CONTROLLER_TYPE_GOOGLE_STADIA
  796. + SDL_GAMEPAD_TYPE_GOOGLE_STADIA
  797. @@
  798. @@
  799. - SDL_CONTROLLER_TYPE_NINTENDO_SWITCH_JOYCON_LEFT
  800. + SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_LEFT
  801. @@
  802. @@
  803. - SDL_CONTROLLER_TYPE_NINTENDO_SWITCH_JOYCON_PAIR
  804. + SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_PAIR
  805. @@
  806. @@
  807. - SDL_CONTROLLER_TYPE_NINTENDO_SWITCH_JOYCON_RIGHT
  808. + SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_JOYCON_RIGHT
  809. @@
  810. @@
  811. - SDL_CONTROLLER_TYPE_NINTENDO_SWITCH_PRO
  812. + SDL_GAMEPAD_TYPE_NINTENDO_SWITCH_PRO
  813. @@
  814. @@
  815. - SDL_CONTROLLER_TYPE_NVIDIA_SHIELD
  816. + SDL_GAMEPAD_TYPE_NVIDIA_SHIELD
  817. @@
  818. @@
  819. - SDL_CONTROLLER_TYPE_PS3
  820. + SDL_GAMEPAD_TYPE_PS3
  821. @@
  822. @@
  823. - SDL_CONTROLLER_TYPE_PS4
  824. + SDL_GAMEPAD_TYPE_PS4
  825. @@
  826. @@
  827. - SDL_CONTROLLER_TYPE_PS5
  828. + SDL_GAMEPAD_TYPE_PS5
  829. @@
  830. @@
  831. - SDL_CONTROLLER_TYPE_UNKNOWN
  832. + SDL_GAMEPAD_TYPE_UNKNOWN
  833. @@
  834. @@
  835. - SDL_CONTROLLER_TYPE_VIRTUAL
  836. + SDL_GAMEPAD_TYPE_VIRTUAL
  837. @@
  838. @@
  839. - SDL_CONTROLLER_TYPE_XBOX360
  840. + SDL_GAMEPAD_TYPE_XBOX360
  841. @@
  842. @@
  843. - SDL_CONTROLLER_TYPE_XBOXONE
  844. + SDL_GAMEPAD_TYPE_XBOXONE
  845. @@
  846. typedef SDL_GameController, SDL_Gamepad;
  847. @@
  848. - SDL_GameController
  849. + SDL_Gamepad
  850. @@
  851. @@
  852. - SDL_GameControllerAddMapping
  853. + SDL_AddGamepadMapping
  854. (...)
  855. @@
  856. @@
  857. - SDL_GameControllerAddMappingsFromFile
  858. + SDL_AddGamepadMappingsFromFile
  859. (...)
  860. @@
  861. @@
  862. - SDL_GameControllerAddMappingsFromRW
  863. + SDL_AddGamepadMappingsFromRW
  864. (...)
  865. @@
  866. typedef SDL_GameControllerAxis, SDL_GamepadAxis;
  867. @@
  868. - SDL_GameControllerAxis
  869. + SDL_GamepadAxis
  870. @@
  871. typedef SDL_GameControllerBindType, SDL_GamepadBindingType;
  872. @@
  873. - SDL_GameControllerBindType
  874. + SDL_GamepadBindingType
  875. @@
  876. typedef SDL_GameControllerButton, SDL_GamepadButton;
  877. @@
  878. - SDL_GameControllerButton
  879. + SDL_GamepadButton
  880. @@
  881. typedef SDL_GameControllerButtonBind, SDL_GamepadBinding;
  882. @@
  883. - SDL_GameControllerButtonBind
  884. + SDL_GamepadBinding
  885. @@
  886. @@
  887. - SDL_GameControllerClose
  888. + SDL_CloseGamepad
  889. (...)
  890. @@
  891. @@
  892. - SDL_GameControllerFromInstanceID
  893. + SDL_GetGamepadFromInstanceID
  894. (...)
  895. @@
  896. @@
  897. - SDL_GameControllerFromPlayerIndex
  898. + SDL_GetGamepadFromPlayerIndex
  899. (...)
  900. @@
  901. @@
  902. - SDL_GameControllerGetAppleSFSymbolsNameForAxis
  903. + SDL_GetGamepadAppleSFSymbolsNameForAxis
  904. (...)
  905. @@
  906. @@
  907. - SDL_GameControllerGetAppleSFSymbolsNameForButton
  908. + SDL_GetGamepadAppleSFSymbolsNameForButton
  909. (...)
  910. @@
  911. @@
  912. - SDL_GameControllerGetAttached
  913. + SDL_GamepadConnected
  914. (...)
  915. @@
  916. @@
  917. - SDL_GameControllerGetAxis
  918. + SDL_GetGamepadAxis
  919. (...)
  920. @@
  921. @@
  922. - SDL_GameControllerGetAxisFromString
  923. + SDL_GetGamepadAxisFromString
  924. (...)
  925. @@
  926. @@
  927. - SDL_GameControllerGetBindForAxis
  928. + SDL_GetGamepadBindForAxis
  929. (...)
  930. @@
  931. @@
  932. - SDL_GameControllerGetBindForButton
  933. + SDL_GetGamepadBindForButton
  934. (...)
  935. @@
  936. @@
  937. - SDL_GameControllerGetButton
  938. + SDL_GetGamepadButton
  939. (...)
  940. @@
  941. @@
  942. - SDL_GameControllerGetButtonFromString
  943. + SDL_GetGamepadButtonFromString
  944. (...)
  945. @@
  946. @@
  947. - SDL_GameControllerGetFirmwareVersion
  948. + SDL_GetGamepadFirmwareVersion
  949. (...)
  950. @@
  951. @@
  952. - SDL_GameControllerGetJoystick
  953. + SDL_GetGamepadJoystick
  954. (...)
  955. @@
  956. @@
  957. - SDL_GameControllerGetNumTouchpadFingers
  958. + SDL_GetGamepadNumTouchpadFingers
  959. (...)
  960. @@
  961. @@
  962. - SDL_GameControllerGetNumTouchpads
  963. + SDL_GetGamepadNumTouchpads
  964. (...)
  965. @@
  966. @@
  967. - SDL_GameControllerGetPlayerIndex
  968. + SDL_GetGamepadPlayerIndex
  969. (...)
  970. @@
  971. @@
  972. - SDL_GameControllerGetProduct
  973. + SDL_GetGamepadProduct
  974. (...)
  975. @@
  976. @@
  977. - SDL_GameControllerGetProductVersion
  978. + SDL_GetGamepadProductVersion
  979. (...)
  980. @@
  981. @@
  982. - SDL_GameControllerGetSensorData
  983. + SDL_GetGamepadSensorData
  984. (...)
  985. @@
  986. @@
  987. - SDL_GameControllerGetSensorDataRate
  988. + SDL_GetGamepadSensorDataRate
  989. (...)
  990. @@
  991. @@
  992. - SDL_GameControllerGetSerial
  993. + SDL_GetGamepadSerial
  994. (...)
  995. @@
  996. @@
  997. - SDL_GameControllerGetStringForAxis
  998. + SDL_GetGamepadStringForAxis
  999. (...)
  1000. @@
  1001. @@
  1002. - SDL_GameControllerGetStringForButton
  1003. + SDL_GetGamepadStringForButton
  1004. (...)
  1005. @@
  1006. @@
  1007. - SDL_GameControllerGetTouchpadFinger
  1008. + SDL_GetGamepadTouchpadFinger
  1009. (...)
  1010. @@
  1011. @@
  1012. - SDL_GameControllerGetType
  1013. + SDL_GetGamepadType
  1014. (...)
  1015. @@
  1016. @@
  1017. - SDL_GameControllerGetVendor
  1018. + SDL_GetGamepadVendor
  1019. (...)
  1020. @@
  1021. @@
  1022. - SDL_GameControllerHasAxis
  1023. + SDL_GamepadHasAxis
  1024. (...)
  1025. @@
  1026. @@
  1027. - SDL_GameControllerHasButton
  1028. + SDL_GamepadHasButton
  1029. (...)
  1030. @@
  1031. @@
  1032. - SDL_GameControllerHasLED
  1033. + SDL_GamepadHasLED
  1034. (...)
  1035. @@
  1036. @@
  1037. - SDL_GameControllerHasRumble
  1038. + SDL_GamepadHasRumble
  1039. (...)
  1040. @@
  1041. @@
  1042. - SDL_GameControllerHasRumbleTriggers
  1043. + SDL_GamepadHasRumbleTriggers
  1044. (...)
  1045. @@
  1046. @@
  1047. - SDL_GameControllerHasSensor
  1048. + SDL_GamepadHasSensor
  1049. (...)
  1050. @@
  1051. @@
  1052. - SDL_GameControllerIsSensorEnabled
  1053. + SDL_GamepadSensorEnabled
  1054. (...)
  1055. @@
  1056. @@
  1057. - SDL_GameControllerMapping
  1058. + SDL_GetGamepadMapping
  1059. (...)
  1060. @@
  1061. @@
  1062. - SDL_GameControllerMappingForGUID
  1063. + SDL_GetGamepadMappingForGUID
  1064. (...)
  1065. @@
  1066. @@
  1067. - SDL_GameControllerMappingForIndex
  1068. + SDL_GetGamepadMappingForIndex
  1069. (...)
  1070. @@
  1071. @@
  1072. - SDL_GameControllerName
  1073. + SDL_GetGamepadName
  1074. (...)
  1075. @@
  1076. @@
  1077. - SDL_GameControllerNumMappings
  1078. + SDL_GetNumGamepadMappings
  1079. (...)
  1080. @@
  1081. @@
  1082. - SDL_GameControllerOpen
  1083. + SDL_OpenGamepad
  1084. (...)
  1085. @@
  1086. @@
  1087. - SDL_GameControllerPath
  1088. + SDL_GetGamepadPath
  1089. (...)
  1090. @@
  1091. @@
  1092. - SDL_GameControllerRumble
  1093. + SDL_RumbleGamepad
  1094. (...)
  1095. @@
  1096. @@
  1097. - SDL_GameControllerRumbleTriggers
  1098. + SDL_RumbleGamepadTriggers
  1099. (...)
  1100. @@
  1101. @@
  1102. - SDL_GameControllerSendEffect
  1103. + SDL_SendGamepadEffect
  1104. (...)
  1105. @@
  1106. @@
  1107. - SDL_GameControllerSetLED
  1108. + SDL_SetGamepadLED
  1109. (...)
  1110. @@
  1111. @@
  1112. - SDL_GameControllerSetPlayerIndex
  1113. + SDL_SetGamepadPlayerIndex
  1114. (...)
  1115. @@
  1116. @@
  1117. - SDL_GameControllerSetSensorEnabled
  1118. + SDL_SetGamepadSensorEnabled
  1119. (...)
  1120. @@
  1121. @@
  1122. - SDL_GameControllerType
  1123. + SDL_GamepadType
  1124. (...)
  1125. @@
  1126. @@
  1127. - SDL_GameControllerUpdate
  1128. + SDL_UpdateGamepads
  1129. (...)
  1130. @@
  1131. @@
  1132. - SDL_INIT_GAMECONTROLLER
  1133. + SDL_INIT_GAMEPAD
  1134. @ rule_init_noparachute @
  1135. @@
  1136. - SDL_INIT_NOPARACHUTE
  1137. + 0
  1138. @@
  1139. @@
  1140. - SDL_JOYSTICK_TYPE_GAMECONTROLLER
  1141. + SDL_JOYSTICK_TYPE_GAMEPAD
  1142. @@
  1143. @@
  1144. - SDL_JoystickAttachVirtual
  1145. + SDL_AttachVirtualJoystick
  1146. (...)
  1147. @@
  1148. @@
  1149. - SDL_JoystickAttachVirtualEx
  1150. + SDL_AttachVirtualJoystickEx
  1151. (...)
  1152. @@
  1153. @@
  1154. - SDL_JoystickClose
  1155. + SDL_CloseJoystick
  1156. (...)
  1157. @@
  1158. @@
  1159. - SDL_JoystickCurrentPowerLevel
  1160. + SDL_GetJoystickPowerLevel
  1161. (...)
  1162. @@
  1163. @@
  1164. - SDL_JoystickDetachVirtual
  1165. + SDL_DetachVirtualJoystick
  1166. (...)
  1167. @@
  1168. @@
  1169. - SDL_JoystickFromInstanceID
  1170. + SDL_GetJoystickFromInstanceID
  1171. (...)
  1172. @@
  1173. @@
  1174. - SDL_JoystickFromPlayerIndex
  1175. + SDL_GetJoystickFromPlayerIndex
  1176. (...)
  1177. @@
  1178. @@
  1179. - SDL_JoystickGetAttached
  1180. + SDL_JoystickConnected
  1181. (...)
  1182. @@
  1183. @@
  1184. - SDL_JoystickGetAxis
  1185. + SDL_GetJoystickAxis
  1186. (...)
  1187. @@
  1188. @@
  1189. - SDL_JoystickGetAxisInitialState
  1190. + SDL_GetJoystickAxisInitialState
  1191. (...)
  1192. @@
  1193. @@
  1194. - SDL_JoystickGetButton
  1195. + SDL_GetJoystickButton
  1196. (...)
  1197. @@
  1198. @@
  1199. - SDL_JoystickGetFirmwareVersion
  1200. + SDL_GetJoystickFirmwareVersion
  1201. (...)
  1202. @@
  1203. @@
  1204. - SDL_JoystickGetGUID
  1205. + SDL_GetJoystickGUID
  1206. (...)
  1207. @@
  1208. @@
  1209. - SDL_JoystickGetGUIDFromString
  1210. + SDL_GetJoystickGUIDFromString
  1211. (...)
  1212. @@
  1213. @@
  1214. - SDL_JoystickGetGUIDString
  1215. + SDL_GetJoystickGUIDString
  1216. (...)
  1217. @@
  1218. @@
  1219. - SDL_JoystickGetHat
  1220. + SDL_GetJoystickHat
  1221. (...)
  1222. @@
  1223. @@
  1224. - SDL_JoystickGetPlayerIndex
  1225. + SDL_GetJoystickPlayerIndex
  1226. (...)
  1227. @@
  1228. @@
  1229. - SDL_JoystickGetProduct
  1230. + SDL_GetJoystickProduct
  1231. (...)
  1232. @@
  1233. @@
  1234. - SDL_JoystickGetProductVersion
  1235. + SDL_GetJoystickProductVersion
  1236. (...)
  1237. @@
  1238. @@
  1239. - SDL_JoystickGetSerial
  1240. + SDL_GetJoystickSerial
  1241. (...)
  1242. @@
  1243. @@
  1244. - SDL_JoystickGetType
  1245. + SDL_GetJoystickType
  1246. (...)
  1247. @@
  1248. @@
  1249. - SDL_JoystickGetVendor
  1250. + SDL_GetJoystickVendor
  1251. (...)
  1252. @@
  1253. @@
  1254. - SDL_JoystickInstanceID
  1255. + SDL_GetJoystickInstanceID
  1256. (...)
  1257. @@
  1258. @@
  1259. - SDL_JoystickName
  1260. + SDL_GetJoystickName
  1261. (...)
  1262. @@
  1263. @@
  1264. - SDL_JoystickNumAxes
  1265. + SDL_GetNumJoystickAxes
  1266. (...)
  1267. @@
  1268. @@
  1269. - SDL_JoystickNumButtons
  1270. + SDL_GetNumJoystickButtons
  1271. (...)
  1272. @@
  1273. @@
  1274. - SDL_JoystickNumHats
  1275. + SDL_GetNumJoystickHats
  1276. (...)
  1277. @@
  1278. @@
  1279. - SDL_JoystickOpen
  1280. + SDL_OpenJoystick
  1281. (...)
  1282. @@
  1283. @@
  1284. - SDL_JoystickPath
  1285. + SDL_GetJoystickPath
  1286. (...)
  1287. @@
  1288. @@
  1289. - SDL_JoystickRumble
  1290. + SDL_RumbleJoystick
  1291. (...)
  1292. @@
  1293. @@
  1294. - SDL_JoystickRumbleTriggers
  1295. + SDL_RumbleJoystickTriggers
  1296. (...)
  1297. @@
  1298. @@
  1299. - SDL_JoystickSendEffect
  1300. + SDL_SendJoystickEffect
  1301. (...)
  1302. @@
  1303. @@
  1304. - SDL_JoystickSetLED
  1305. + SDL_SetJoystickLED
  1306. (...)
  1307. @@
  1308. @@
  1309. - SDL_JoystickSetPlayerIndex
  1310. + SDL_SetJoystickPlayerIndex
  1311. (...)
  1312. @@
  1313. @@
  1314. - SDL_JoystickSetVirtualAxis
  1315. + SDL_SetJoystickVirtualAxis
  1316. (...)
  1317. @@
  1318. @@
  1319. - SDL_JoystickSetVirtualButton
  1320. + SDL_SetJoystickVirtualButton
  1321. (...)
  1322. @@
  1323. @@
  1324. - SDL_JoystickSetVirtualHat
  1325. + SDL_SetJoystickVirtualHat
  1326. (...)
  1327. @@
  1328. @@
  1329. - SDL_JoystickUpdate
  1330. + SDL_UpdateJoysticks
  1331. (...)
  1332. @@
  1333. @@
  1334. - SDL_IsScreenKeyboardShown
  1335. + SDL_ScreenKeyboardShown
  1336. (...)
  1337. @@
  1338. @@
  1339. - SDL_IsTextInputActive
  1340. + SDL_TextInputActive
  1341. (...)
  1342. @@
  1343. @@
  1344. - SDL_IsTextInputShown
  1345. + SDL_TextInputShown
  1346. (...)
  1347. @@
  1348. @@
  1349. - KMOD_ALT
  1350. + SDL_KMOD_ALT
  1351. @@
  1352. @@
  1353. - KMOD_CAPS
  1354. + SDL_KMOD_CAPS
  1355. @@
  1356. @@
  1357. - KMOD_CTRL
  1358. + SDL_KMOD_CTRL
  1359. @@
  1360. @@
  1361. - KMOD_GUI
  1362. + SDL_KMOD_GUI
  1363. @@
  1364. @@
  1365. - KMOD_LALT
  1366. + SDL_KMOD_LALT
  1367. @@
  1368. @@
  1369. - KMOD_LCTRL
  1370. + SDL_KMOD_LCTRL
  1371. @@
  1372. @@
  1373. - KMOD_LGUI
  1374. + SDL_KMOD_LGUI
  1375. @@
  1376. @@
  1377. - KMOD_LSHIFT
  1378. + SDL_KMOD_LSHIFT
  1379. @@
  1380. @@
  1381. - KMOD_MODE
  1382. + SDL_KMOD_MODE
  1383. @@
  1384. @@
  1385. - KMOD_NONE
  1386. + SDL_KMOD_NONE
  1387. @@
  1388. @@
  1389. - KMOD_NUM
  1390. + SDL_KMOD_NUM
  1391. @@
  1392. @@
  1393. - KMOD_RALT
  1394. + SDL_KMOD_RALT
  1395. @@
  1396. @@
  1397. - KMOD_RCTRL
  1398. + SDL_KMOD_RCTRL
  1399. @@
  1400. @@
  1401. - KMOD_RESERVED
  1402. + SDL_KMOD_RESERVED
  1403. @@
  1404. @@
  1405. - KMOD_RGUI
  1406. + SDL_KMOD_RGUI
  1407. @@
  1408. @@
  1409. - KMOD_RSHIFT
  1410. + SDL_KMOD_RSHIFT
  1411. @@
  1412. @@
  1413. - KMOD_SCROLL
  1414. + SDL_KMOD_SCROLL
  1415. @@
  1416. @@
  1417. - KMOD_SHIFT
  1418. + SDL_KMOD_SHIFT
  1419. @@
  1420. @@
  1421. - SDL_FreeCursor
  1422. + SDL_DestroyCursor
  1423. (...)
  1424. @@
  1425. @@
  1426. - SDL_AllocFormat
  1427. + SDL_CreatePixelFormat
  1428. (...)
  1429. @@
  1430. @@
  1431. - SDL_AllocPalette
  1432. + SDL_CreatePalette
  1433. (...)
  1434. @@
  1435. @@
  1436. - SDL_FreeFormat
  1437. + SDL_DestroyPixelFormat
  1438. (...)
  1439. @@
  1440. @@
  1441. - SDL_FreePalette
  1442. + SDL_DestroyPalette
  1443. (...)
  1444. @@
  1445. @@
  1446. - SDL_MasksToPixelFormatEnum
  1447. + SDL_GetPixelFormatEnumForMasks
  1448. (...)
  1449. @@
  1450. @@
  1451. - SDL_PixelFormatEnumToMasks
  1452. + SDL_GetMasksForPixelFormatEnum
  1453. (...)
  1454. @@
  1455. @@
  1456. - SDL_EncloseFPoints
  1457. + SDL_GetRectEnclosingPointsFloat
  1458. (...)
  1459. @@
  1460. @@
  1461. - SDL_EnclosePoints
  1462. + SDL_GetRectEnclosingPoints
  1463. (...)
  1464. @@
  1465. @@
  1466. - SDL_FRectEmpty
  1467. + SDL_RectEmptyFloat
  1468. (...)
  1469. @@
  1470. @@
  1471. - SDL_FRectEquals
  1472. + SDL_RectsEqualFloat
  1473. (...)
  1474. @@
  1475. @@
  1476. - SDL_FRectEqualsEpsilon
  1477. + SDL_RectsEqualEpsilon
  1478. (...)
  1479. @@
  1480. @@
  1481. - SDL_HasIntersection
  1482. + SDL_HasRectIntersection
  1483. (...)
  1484. @@
  1485. @@
  1486. - SDL_HasIntersectionF
  1487. + SDL_HasRectIntersectionFloat
  1488. (...)
  1489. @@
  1490. @@
  1491. - SDL_IntersectFRect
  1492. + SDL_GetRectIntersectionFloat
  1493. (...)
  1494. @@
  1495. @@
  1496. - SDL_IntersectFRectAndLine
  1497. + SDL_GetRectAndLineIntersectionFloat
  1498. (...)
  1499. @@
  1500. @@
  1501. - SDL_IntersectRect
  1502. + SDL_GetRectIntersection
  1503. (...)
  1504. @@
  1505. @@
  1506. - SDL_IntersectRectAndLine
  1507. + SDL_GetRectAndLineIntersection
  1508. (...)
  1509. @@
  1510. @@
  1511. - SDL_PointInFRect
  1512. + SDL_PointInRectFloat
  1513. (...)
  1514. @@
  1515. @@
  1516. - SDL_RectEquals
  1517. + SDL_RectsEqual
  1518. (...)
  1519. @@
  1520. @@
  1521. - SDL_UnionFRect
  1522. + SDL_GetRectUnionFloat
  1523. (...)
  1524. @@
  1525. @@
  1526. - SDL_UnionRect
  1527. + SDL_GetRectUnion
  1528. (...)
  1529. @@
  1530. @@
  1531. - SDL_RenderCopyExF
  1532. + SDL_RenderTextureRotated
  1533. (...)
  1534. @@
  1535. @@
  1536. - SDL_RenderCopyF
  1537. + SDL_RenderTexture
  1538. (...)
  1539. @@
  1540. @@
  1541. - SDL_RenderDrawLineF
  1542. + SDL_RenderLine
  1543. (...)
  1544. @@
  1545. @@
  1546. - SDL_RenderDrawLinesF
  1547. + SDL_RenderLines
  1548. (...)
  1549. @@
  1550. @@
  1551. - SDL_RenderDrawPointF
  1552. + SDL_RenderPoint
  1553. (...)
  1554. @@
  1555. @@
  1556. - SDL_RenderDrawPointsF
  1557. + SDL_RenderPoints
  1558. (...)
  1559. @@
  1560. @@
  1561. - SDL_RenderDrawRectF
  1562. + SDL_RenderRect
  1563. (...)
  1564. @@
  1565. @@
  1566. - SDL_RenderDrawRectsF
  1567. + SDL_RenderRects
  1568. (...)
  1569. @@
  1570. @@
  1571. - SDL_RenderFillRectF
  1572. + SDL_RenderFillRect
  1573. (...)
  1574. @@
  1575. @@
  1576. - SDL_RenderFillRectsF
  1577. + SDL_RenderFillRects
  1578. (...)
  1579. @@
  1580. @@
  1581. - SDL_RenderGetClipRect
  1582. + SDL_GetRenderClipRect
  1583. (...)
  1584. @@
  1585. SDL_Renderer *renderer;
  1586. int *e1;
  1587. int *e2;
  1588. @@
  1589. - SDL_RenderGetLogicalSize(renderer, e1, e2)
  1590. + SDL_GetRenderLogicalPresentation(renderer, e1, e2, NULL, NULL)
  1591. @@
  1592. @@
  1593. - SDL_RenderGetMetalCommandEncoder
  1594. + SDL_GetRenderMetalCommandEncoder
  1595. (...)
  1596. @@
  1597. @@
  1598. - SDL_RenderGetMetalLayer
  1599. + SDL_GetRenderMetalLayer
  1600. (...)
  1601. @@
  1602. @@
  1603. - SDL_RenderGetScale
  1604. + SDL_GetRenderScale
  1605. (...)
  1606. @@
  1607. @@
  1608. - SDL_RenderGetViewport
  1609. + SDL_GetRenderViewport
  1610. (...)
  1611. @@
  1612. @@
  1613. - SDL_RenderGetWindow
  1614. + SDL_GetRenderWindow
  1615. (...)
  1616. @@
  1617. @@
  1618. - SDL_RenderIsClipEnabled
  1619. + SDL_RenderClipEnabled
  1620. (...)
  1621. @@
  1622. @@
  1623. - SDL_RenderSetClipRect
  1624. + SDL_SetRenderClipRect
  1625. (...)
  1626. @@
  1627. SDL_Renderer *renderer;
  1628. expression e1;
  1629. expression e2;
  1630. @@
  1631. (
  1632. - SDL_RenderSetLogicalSize(renderer, 0, 0)
  1633. + SDL_SetRenderLogicalPresentation(renderer, 0, 0, SDL_LOGICAL_PRESENTATION_DISABLED, SDL_ScaleModeNearest)
  1634. |
  1635. - SDL_RenderSetLogicalSize(renderer, e1, e2)
  1636. + SDL_SetRenderLogicalPresentation(renderer, e1, e2, SDL_LOGICAL_PRESENTATION_LETTERBOX, SDL_ScaleModeLinear)
  1637. )
  1638. @@
  1639. @@
  1640. - SDL_RenderSetScale
  1641. + SDL_SetRenderScale
  1642. (...)
  1643. @@
  1644. @@
  1645. - SDL_RenderSetVSync
  1646. + SDL_SetRenderVSync
  1647. (...)
  1648. @@
  1649. @@
  1650. - SDL_RenderSetViewport
  1651. + SDL_SetRenderViewport
  1652. (...)
  1653. @@
  1654. @@
  1655. - RW_SEEK_CUR
  1656. + SDL_RW_SEEK_CUR
  1657. @@
  1658. @@
  1659. - RW_SEEK_END
  1660. + SDL_RW_SEEK_END
  1661. @@
  1662. @@
  1663. - RW_SEEK_SET
  1664. + SDL_RW_SEEK_SET
  1665. @@
  1666. @@
  1667. - SDL_AllocRW
  1668. + SDL_CreateRW
  1669. (...)
  1670. @@
  1671. @@
  1672. - SDL_FreeRW
  1673. + SDL_DestroyRW
  1674. (...)
  1675. @@
  1676. @@
  1677. - SDL_SensorClose
  1678. + SDL_CloseSensor
  1679. (...)
  1680. @@
  1681. @@
  1682. - SDL_SensorFromInstanceID
  1683. + SDL_GetSensorFromInstanceID
  1684. (...)
  1685. @@
  1686. @@
  1687. - SDL_SensorGetData
  1688. + SDL_GetSensorData
  1689. (...)
  1690. @@
  1691. @@
  1692. - SDL_SensorGetInstanceID
  1693. + SDL_GetSensorInstanceID
  1694. (...)
  1695. @@
  1696. @@
  1697. - SDL_SensorGetName
  1698. + SDL_GetSensorName
  1699. (...)
  1700. @@
  1701. @@
  1702. - SDL_SensorGetNonPortableType
  1703. + SDL_GetSensorNonPortableType
  1704. (...)
  1705. @@
  1706. @@
  1707. - SDL_SensorGetType
  1708. + SDL_GetSensorType
  1709. (...)
  1710. @@
  1711. @@
  1712. - SDL_SensorOpen
  1713. + SDL_OpenSensor
  1714. (...)
  1715. @@
  1716. @@
  1717. - SDL_SensorUpdate
  1718. + SDL_UpdateSensors
  1719. (...)
  1720. @@
  1721. @@
  1722. - SDL_FillRect
  1723. + SDL_FillSurfaceRect
  1724. (...)
  1725. @@
  1726. @@
  1727. - SDL_FillRects
  1728. + SDL_FillSurfaceRects
  1729. (...)
  1730. @@
  1731. @@
  1732. - SDL_FreeSurface
  1733. + SDL_DestroySurface
  1734. (...)
  1735. @@
  1736. @@
  1737. - SDL_GetClipRect
  1738. + SDL_GetSurfaceClipRect
  1739. (...)
  1740. @@
  1741. @@
  1742. - SDL_GetColorKey
  1743. + SDL_GetSurfaceColorKey
  1744. (...)
  1745. @@
  1746. @@
  1747. - SDL_HasColorKey
  1748. + SDL_SurfaceHasColorKey
  1749. (...)
  1750. @@
  1751. @@
  1752. - SDL_HasSurfaceRLE
  1753. + SDL_SurfaceHasRLE
  1754. (...)
  1755. @@
  1756. @@
  1757. - SDL_LowerBlit
  1758. + SDL_BlitSurfaceUnchecked
  1759. (...)
  1760. @@
  1761. @@
  1762. - SDL_LowerBlitScaled
  1763. + SDL_BlitSurfaceUncheckedScaled
  1764. (...)
  1765. @@
  1766. @@
  1767. - SDL_SetClipRect
  1768. + SDL_SetSurfaceClipRect
  1769. (...)
  1770. @@
  1771. @@
  1772. - SDL_SetColorKey
  1773. + SDL_SetSurfaceColorKey
  1774. (...)
  1775. @@
  1776. @@
  1777. - SDL_UpperBlit
  1778. + SDL_BlitSurface
  1779. (...)
  1780. @@
  1781. @@
  1782. - SDL_UpperBlitScaled
  1783. + SDL_BlitSurfaceScaled
  1784. (...)
  1785. @@
  1786. @@
  1787. - SDL_RenderGetD3D11Device
  1788. + SDL_GetRenderD3D11Device
  1789. (...)
  1790. @@
  1791. @@
  1792. - SDL_RenderGetD3D9Device
  1793. + SDL_GetRenderD3D9Device
  1794. (...)
  1795. @@
  1796. @@
  1797. - SDL_GetTicks64
  1798. + SDL_GetTicks
  1799. (...)
  1800. @@
  1801. @@
  1802. - SDL_GetPointDisplayIndex
  1803. + SDL_GetDisplayForPoint
  1804. (...)
  1805. @@
  1806. @@
  1807. - SDL_GetRectDisplayIndex
  1808. + SDL_GetDisplayForRect
  1809. (...)
  1810. @ depends on rule_init_noparachute @
  1811. expression e;
  1812. @@
  1813. - e | 0
  1814. + e
  1815. @@
  1816. @@
  1817. - SDL_FIRSTEVENT
  1818. + SDL_EVENT_FIRST
  1819. @@
  1820. @@
  1821. - SDL_QUIT
  1822. + SDL_EVENT_QUIT
  1823. @@
  1824. @@
  1825. - SDL_APP_TERMINATING
  1826. + SDL_EVENT_TERMINATING
  1827. @@
  1828. @@
  1829. - SDL_APP_LOWMEMORY
  1830. + SDL_EVENT_LOW_MEMORY
  1831. @@
  1832. @@
  1833. - SDL_APP_WILLENTERBACKGROUND
  1834. + SDL_EVENT_WILL_ENTER_BACKGROUND
  1835. @@
  1836. @@
  1837. - SDL_APP_DIDENTERBACKGROUND
  1838. + SDL_EVENT_DID_ENTER_BACKGROUND
  1839. @@
  1840. @@
  1841. - SDL_APP_WILLENTERFOREGROUND
  1842. + SDL_EVENT_WILL_ENTER_FOREGROUND
  1843. @@
  1844. @@
  1845. - SDL_APP_DIDENTERFOREGROUND
  1846. + SDL_EVENT_DID_ENTER_FOREGROUND
  1847. @@
  1848. @@
  1849. - SDL_LOCALECHANGED
  1850. + SDL_EVENT_LOCALE_CHANGED
  1851. @@
  1852. @@
  1853. - SDL_DISPLAYEVENT_ORIENTATION
  1854. + SDL_EVENT_DISPLAY_ORIENTATION
  1855. @@
  1856. @@
  1857. - SDL_DISPLAYEVENT_CONNECTED
  1858. + SDL_EVENT_DISPLAY_CONNECTED
  1859. @@
  1860. @@
  1861. - SDL_DISPLAYEVENT_DISCONNECTED
  1862. + SDL_EVENT_DISPLAY_DISCONNECTED
  1863. @@
  1864. @@
  1865. - SDL_DISPLAYEVENT_MOVED
  1866. + SDL_EVENT_DISPLAY_MOVED
  1867. @@
  1868. @@
  1869. - SDL_DISPLAYEVENT_FIRST
  1870. + SDL_EVENT_DISPLAY_FIRST
  1871. @@
  1872. @@
  1873. - SDL_DISPLAYEVENT_LAST
  1874. + SDL_EVENT_DISPLAY_LAST
  1875. @@
  1876. @@
  1877. - SDL_SYSWMEVENT
  1878. + SDL_EVENT_SYSWM
  1879. @@
  1880. @@
  1881. - SDL_WINDOWEVENT_SHOWN
  1882. + SDL_EVENT_WINDOW_SHOWN
  1883. @@
  1884. @@
  1885. - SDL_WINDOWEVENT_HIDDEN
  1886. + SDL_EVENT_WINDOW_HIDDEN
  1887. @@
  1888. @@
  1889. - SDL_WINDOWEVENT_EXPOSED
  1890. + SDL_EVENT_WINDOW_EXPOSED
  1891. @@
  1892. @@
  1893. - SDL_WINDOWEVENT_MOVED
  1894. + SDL_EVENT_WINDOW_MOVED
  1895. @@
  1896. @@
  1897. - SDL_WINDOWEVENT_RESIZED
  1898. + SDL_EVENT_WINDOW_RESIZED
  1899. @@
  1900. @@
  1901. - SDL_WINDOWEVENT_SIZE_CHANGED
  1902. + SDL_EVENT_WINDOW_SIZE_CHANGED
  1903. @@
  1904. @@
  1905. - SDL_WINDOWEVENT_MINIMIZED
  1906. + SDL_EVENT_WINDOW_MINIMIZED
  1907. @@
  1908. @@
  1909. - SDL_WINDOWEVENT_MAXIMIZED
  1910. + SDL_EVENT_WINDOW_MAXIMIZED
  1911. @@
  1912. @@
  1913. - SDL_WINDOWEVENT_RESTORED
  1914. + SDL_EVENT_WINDOW_RESTORED
  1915. @@
  1916. @@
  1917. - SDL_WINDOWEVENT_ENTER
  1918. + SDL_EVENT_WINDOW_MOUSE_ENTER
  1919. @@
  1920. @@
  1921. - SDL_WINDOWEVENT_LEAVE
  1922. + SDL_EVENT_WINDOW_MOUSE_LEAVE
  1923. @@
  1924. @@
  1925. - SDL_WINDOWEVENT_FOCUS_GAINED
  1926. + SDL_EVENT_WINDOW_FOCUS_GAINED
  1927. @@
  1928. @@
  1929. - SDL_WINDOWEVENT_FOCUS_LOST
  1930. + SDL_EVENT_WINDOW_FOCUS_LOST
  1931. @@
  1932. @@
  1933. - SDL_WINDOWEVENT_CLOSE
  1934. + SDL_EVENT_WINDOW_CLOSE_REQUESTED
  1935. @@
  1936. @@
  1937. - SDL_WINDOWEVENT_TAKE_FOCUS
  1938. + SDL_EVENT_WINDOW_TAKE_FOCUS
  1939. @@
  1940. @@
  1941. - SDL_WINDOWEVENT_HIT_TEST
  1942. + SDL_EVENT_WINDOW_HIT_TEST
  1943. @@
  1944. @@
  1945. - SDL_WINDOWEVENT_ICCPROF_CHANGED
  1946. + SDL_EVENT_WINDOW_ICCPROF_CHANGED
  1947. @@
  1948. @@
  1949. - SDL_WINDOWEVENT_DISPLAY_CHANGED
  1950. + SDL_EVENT_WINDOW_DISPLAY_CHANGED
  1951. @@
  1952. @@
  1953. - SDL_WINDOWEVENT_FIRST
  1954. + SDL_EVENT_WINDOW_FIRST
  1955. @@
  1956. @@
  1957. - SDL_WINDOWEVENT_LAST
  1958. + SDL_EVENT_WINDOW_LAST
  1959. @@
  1960. @@
  1961. - SDL_KEYDOWN
  1962. + SDL_EVENT_KEY_DOWN
  1963. @@
  1964. @@
  1965. - SDL_KEYUP
  1966. + SDL_EVENT_KEY_UP
  1967. @@
  1968. @@
  1969. - SDL_TEXTEDITING
  1970. + SDL_EVENT_TEXT_EDITING
  1971. @@
  1972. @@
  1973. - SDL_TEXTINPUT
  1974. + SDL_EVENT_TEXT_INPUT
  1975. @@
  1976. @@
  1977. - SDL_KEYMAPCHANGED
  1978. + SDL_EVENT_KEYMAP_CHANGED
  1979. @@
  1980. @@
  1981. - SDL_TEXTEDITING_EXT
  1982. + SDL_EVENT_TEXT_EDITING_EXT
  1983. @@
  1984. @@
  1985. - SDL_MOUSEMOTION
  1986. + SDL_EVENT_MOUSE_MOTION
  1987. @@
  1988. @@
  1989. - SDL_MOUSEBUTTONDOWN
  1990. + SDL_EVENT_MOUSE_BUTTON_DOWN
  1991. @@
  1992. @@
  1993. - SDL_MOUSEBUTTONUP
  1994. + SDL_EVENT_MOUSE_BUTTON_UP
  1995. @@
  1996. @@
  1997. - SDL_MOUSEWHEEL
  1998. + SDL_EVENT_MOUSE_WHEEL
  1999. @@
  2000. @@
  2001. - SDL_JOYAXISMOTION
  2002. + SDL_EVENT_JOYSTICK_AXIS_MOTION
  2003. @@
  2004. @@
  2005. - SDL_JOYHATMOTION
  2006. + SDL_EVENT_JOYSTICK_HAT_MOTION
  2007. @@
  2008. @@
  2009. - SDL_JOYBUTTONDOWN
  2010. + SDL_EVENT_JOYSTICK_BUTTON_DOWN
  2011. @@
  2012. @@
  2013. - SDL_JOYBUTTONUP
  2014. + SDL_EVENT_JOYSTICK_BUTTON_UP
  2015. @@
  2016. @@
  2017. - SDL_JOYDEVICEADDED
  2018. + SDL_EVENT_JOYSTICK_ADDED
  2019. @@
  2020. @@
  2021. - SDL_JOYDEVICEREMOVED
  2022. + SDL_EVENT_JOYSTICK_REMOVED
  2023. @@
  2024. @@
  2025. - SDL_JOYBATTERYUPDATED
  2026. + SDL_EVENT_JOYSTICK_BATTERY_UPDATED
  2027. @@
  2028. @@
  2029. - SDL_GAMEPADAXISMOTION
  2030. + SDL_EVENT_GAMEPAD_AXIS_MOTION
  2031. @@
  2032. @@
  2033. - SDL_GAMEPADBUTTONDOWN
  2034. + SDL_EVENT_GAMEPAD_BUTTON_DOWN
  2035. @@
  2036. @@
  2037. - SDL_GAMEPADBUTTONUP
  2038. + SDL_EVENT_GAMEPAD_BUTTON_UP
  2039. @@
  2040. @@
  2041. - SDL_GAMEPADADDED
  2042. + SDL_EVENT_GAMEPAD_ADDED
  2043. @@
  2044. @@
  2045. - SDL_GAMEPADREMOVED
  2046. + SDL_EVENT_GAMEPAD_REMOVED
  2047. @@
  2048. @@
  2049. - SDL_GAMEPADREMAPPED
  2050. + SDL_EVENT_GAMEPAD_REMAPPED
  2051. @@
  2052. @@
  2053. - SDL_GAMEPADTOUCHPADDOWN
  2054. + SDL_EVENT_GAMEPAD_TOUCHPAD_DOWN
  2055. @@
  2056. @@
  2057. - SDL_GAMEPADTOUCHPADMOTION
  2058. + SDL_EVENT_GAMEPAD_TOUCHPAD_MOTION
  2059. @@
  2060. @@
  2061. - SDL_GAMEPADTOUCHPADUP
  2062. + SDL_EVENT_GAMEPAD_TOUCHPAD_UP
  2063. @@
  2064. @@
  2065. - SDL_GAMEPADSENSORUPDATE
  2066. + SDL_EVENT_GAMEPAD_SENSOR_UPDATE
  2067. @@
  2068. @@
  2069. - SDL_FINGERDOWN
  2070. + SDL_EVENT_FINGER_DOWN
  2071. @@
  2072. @@
  2073. - SDL_FINGERUP
  2074. + SDL_EVENT_FINGER_UP
  2075. @@
  2076. @@
  2077. - SDL_FINGERMOTION
  2078. + SDL_EVENT_FINGER_MOTION
  2079. @@
  2080. @@
  2081. - SDL_CLIPBOARDUPDATE
  2082. + SDL_EVENT_CLIPBOARD_UPDATE
  2083. @@
  2084. @@
  2085. - SDL_DROPFILE
  2086. + SDL_EVENT_DROP_FILE
  2087. @@
  2088. @@
  2089. - SDL_DROPTEXT
  2090. + SDL_EVENT_DROP_TEXT
  2091. @@
  2092. @@
  2093. - SDL_DROPBEGIN
  2094. + SDL_EVENT_DROP_BEGIN
  2095. @@
  2096. @@
  2097. - SDL_DROPCOMPLETE
  2098. + SDL_EVENT_DROP_COMPLETE
  2099. @@
  2100. @@
  2101. - SDL_AUDIODEVICEADDED
  2102. + SDL_EVENT_AUDIO_DEVICE_ADDED
  2103. @@
  2104. @@
  2105. - SDL_AUDIODEVICEREMOVED
  2106. + SDL_EVENT_AUDIO_DEVICE_REMOVED
  2107. @@
  2108. @@
  2109. - SDL_SENSORUPDATE
  2110. + SDL_EVENT_SENSOR_UPDATE
  2111. @@
  2112. @@
  2113. - SDL_RENDER_TARGETS_RESET
  2114. + SDL_EVENT_RENDER_TARGETS_RESET
  2115. @@
  2116. @@
  2117. - SDL_RENDER_DEVICE_RESET
  2118. + SDL_EVENT_RENDER_DEVICE_RESET
  2119. @@
  2120. @@
  2121. - SDL_POLLSENTINEL
  2122. + SDL_EVENT_POLL_SENTINEL
  2123. @@
  2124. @@
  2125. - SDL_USEREVENT
  2126. + SDL_EVENT_USER
  2127. @@
  2128. @@
  2129. - SDL_LASTEVENT
  2130. + SDL_EVENT_LAST
  2131. @@
  2132. @@
  2133. - SDL_GetDisplayDPI
  2134. + SDL_GetDisplayPhysicalDPI
  2135. (...)
  2136. @@
  2137. @@
  2138. - SDL_WINDOW_INPUT_GRABBED
  2139. + SDL_WINDOW_MOUSE_GRABBED
  2140. @@
  2141. SDL_DisplayMode *e;
  2142. @@
  2143. (
  2144. - e->w
  2145. + e->screen_w
  2146. |
  2147. - e->h
  2148. + e->screen_h
  2149. )
  2150. @@
  2151. SDL_DisplayMode e;
  2152. @@
  2153. (
  2154. - e.w
  2155. + e.screen_w
  2156. |
  2157. - e.h
  2158. + e.screen_h
  2159. )
  2160. @@
  2161. @@
  2162. - SDL_GetWindowDisplayIndex
  2163. + SDL_GetDisplayForWindow
  2164. (...)
  2165. @@
  2166. @@
  2167. - SDL_SetWindowDisplayMode
  2168. + SDL_SetWindowFullscreenMode
  2169. (...)
  2170. @@
  2171. @@
  2172. - SDL_GetWindowDisplayMode
  2173. + SDL_GetWindowFullscreenMode
  2174. (...)
  2175. @@
  2176. @@
  2177. - SDL_GetClosestDisplayMode
  2178. + SDL_GetClosestFullscreenDisplayMode
  2179. (...)
  2180. @@
  2181. @@
  2182. - SDL_GetRendererOutputSize
  2183. + SDL_GetCurrentRenderOutputSizeInPixels
  2184. (...)
  2185. @@
  2186. @@
  2187. - SDL_RenderWindowToLogical
  2188. + SDL_RenderCoordinatesFromWindow
  2189. (...)
  2190. @@
  2191. @@
  2192. - SDL_RenderLogicalToWindow
  2193. + SDL_RenderCoordinatesToWindow
  2194. (...)
  2195. @@
  2196. symbol SDL_ScaleModeNearest;
  2197. @@
  2198. - SDL_ScaleModeNearest
  2199. + SDL_SCALEMODE_NEAREST
  2200. @@
  2201. symbol SDL_ScaleModeLinear;
  2202. @@
  2203. - SDL_ScaleModeLinear
  2204. + SDL_SCALEMODE_LINEAR
  2205. @@
  2206. symbol SDL_ScaleModeBest;
  2207. @@
  2208. - SDL_ScaleModeBest
  2209. + SDL_SCALEMODE_BEST
  2210. @@
  2211. @@
  2212. - SDL_RenderCopy
  2213. + SDL_RenderTexture
  2214. (...)
  2215. @@
  2216. @@
  2217. - SDL_RenderCopyEx
  2218. + SDL_RenderTextureRotated
  2219. (...)
  2220. @@
  2221. SDL_Renderer *renderer;
  2222. constant c1;
  2223. constant c2;
  2224. constant c3;
  2225. constant c4;
  2226. expression e1;
  2227. expression e2;
  2228. expression e3;
  2229. expression e4;
  2230. @@
  2231. - SDL_RenderDrawLine(renderer,
  2232. + SDL_RenderLine(renderer,
  2233. (
  2234. c1
  2235. |
  2236. - e1
  2237. + (float)e1
  2238. )
  2239. ,
  2240. (
  2241. c2
  2242. |
  2243. - e2
  2244. + (float)e2
  2245. )
  2246. ,
  2247. (
  2248. c3
  2249. |
  2250. - e3
  2251. + (float)e3
  2252. )
  2253. ,
  2254. (
  2255. c4
  2256. |
  2257. - e4
  2258. + (float)e4
  2259. )
  2260. )
  2261. @@
  2262. @@
  2263. - SDL_RenderDrawLines
  2264. + SDL_RenderLines
  2265. (...)
  2266. @@
  2267. SDL_Renderer *renderer;
  2268. constant c1;
  2269. constant c2;
  2270. expression e1;
  2271. expression e2;
  2272. @@
  2273. - SDL_RenderDrawPoint(renderer,
  2274. + SDL_RenderPoint(renderer,
  2275. (
  2276. c1
  2277. |
  2278. - e1
  2279. + (float)e1
  2280. )
  2281. ,
  2282. (
  2283. c2
  2284. |
  2285. - e2
  2286. + (float)e2
  2287. )
  2288. )
  2289. @@
  2290. @@
  2291. - SDL_RenderDrawPoints
  2292. + SDL_RenderPoints
  2293. (...)
  2294. @@
  2295. @@
  2296. - SDL_RenderDrawRect
  2297. + SDL_RenderRect
  2298. (...)
  2299. @@
  2300. @@
  2301. - SDL_RenderDrawRects
  2302. + SDL_RenderRects
  2303. (...)