ruby2d 0.11.1 → 0.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/assets/include/SDL2/SDL.h +108 -14
- data/assets/include/SDL2/SDL_assert.h +81 -50
- data/assets/include/SDL2/SDL_atomic.h +135 -35
- data/assets/include/SDL2/SDL_audio.h +960 -355
- data/assets/include/SDL2/SDL_bits.h +11 -6
- data/assets/include/SDL2/SDL_blendmode.h +91 -14
- data/assets/include/SDL2/SDL_clipboard.h +30 -7
- data/assets/include/SDL2/SDL_config.h +3 -1
- data/assets/include/SDL2/SDL_config_android.h +11 -1
- data/assets/include/SDL2/SDL_config_emscripten.h +216 -0
- data/assets/include/SDL2/SDL_config_iphoneos.h +9 -1
- data/assets/include/SDL2/SDL_config_macosx.h +16 -2
- data/assets/include/SDL2/SDL_config_minimal.h +4 -1
- data/assets/include/SDL2/SDL_config_os2.h +37 -20
- data/assets/include/SDL2/SDL_config_pandora.h +6 -1
- data/assets/include/SDL2/SDL_config_psp.h +8 -8
- data/assets/include/SDL2/SDL_config_windows.h +39 -22
- data/assets/include/SDL2/SDL_config_winrt.h +23 -8
- data/assets/include/SDL2/SDL_config_wiz.h +6 -1
- data/assets/include/SDL2/SDL_copying.h +1 -1
- data/assets/include/SDL2/SDL_cpuinfo.h +331 -71
- data/assets/include/SDL2/SDL_egl.h +906 -280
- data/assets/include/SDL2/SDL_endian.h +101 -47
- data/assets/include/SDL2/SDL_error.h +70 -19
- data/assets/include/SDL2/SDL_events.h +387 -79
- data/assets/include/SDL2/SDL_filesystem.h +73 -64
- data/assets/include/SDL2/SDL_gamecontroller.h +585 -125
- data/assets/include/SDL2/SDL_gesture.h +36 -6
- data/assets/include/SDL2/SDL_haptic.h +304 -210
- data/assets/include/SDL2/SDL_hidapi.h +451 -0
- data/assets/include/SDL2/SDL_hints.h +1286 -897
- data/assets/include/SDL2/SDL_joystick.h +577 -130
- data/assets/include/SDL2/SDL_keyboard.h +162 -63
- data/assets/include/SDL2/SDL_keycode.h +7 -5
- data/assets/include/SDL2/SDL_loadso.h +42 -8
- data/assets/include/SDL2/SDL_locale.h +34 -32
- data/assets/include/SDL2/SDL_log.h +212 -19
- data/assets/include/SDL2/SDL_main.h +72 -17
- data/assets/include/SDL2/SDL_messagebox.h +70 -23
- data/assets/include/SDL2/SDL_metal.h +27 -32
- data/assets/include/SDL2/SDL_misc.h +19 -15
- data/assets/include/SDL2/SDL_mouse.h +262 -110
- data/assets/include/SDL2/SDL_mutex.h +286 -66
- data/assets/include/SDL2/SDL_name.h +1 -1
- data/assets/include/SDL2/SDL_opengl.h +1 -1
- data/assets/include/SDL2/SDL_opengles.h +1 -1
- data/assets/include/SDL2/SDL_opengles2.h +2 -2
- data/assets/include/SDL2/SDL_pixels.h +199 -34
- data/assets/include/SDL2/SDL_platform.h +39 -2
- data/assets/include/SDL2/SDL_power.h +23 -10
- data/assets/include/SDL2/SDL_quit.h +1 -1
- data/assets/include/SDL2/SDL_rect.h +78 -28
- data/assets/include/SDL2/SDL_render.h +1204 -472
- data/assets/include/SDL2/SDL_revision.h +2 -2
- data/assets/include/SDL2/SDL_rwops.h +605 -33
- data/assets/include/SDL2/SDL_scancode.h +1 -1
- data/assets/include/SDL2/SDL_sensor.h +76 -42
- data/assets/include/SDL2/SDL_shape.h +38 -27
- data/assets/include/SDL2/SDL_stdinc.h +96 -24
- data/assets/include/SDL2/SDL_surface.h +571 -139
- data/assets/include/SDL2/SDL_system.h +339 -101
- data/assets/include/SDL2/SDL_syswm.h +50 -20
- data/assets/include/SDL2/SDL_test.h +1 -1
- data/assets/include/SDL2/SDL_test_assert.h +2 -2
- data/assets/include/SDL2/SDL_test_common.h +23 -6
- data/assets/include/SDL2/SDL_test_compare.h +1 -1
- data/assets/include/SDL2/SDL_test_crc32.h +1 -1
- data/assets/include/SDL2/SDL_test_font.h +3 -3
- data/assets/include/SDL2/SDL_test_fuzzer.h +28 -26
- data/assets/include/SDL2/SDL_test_harness.h +6 -6
- data/assets/include/SDL2/SDL_test_images.h +1 -1
- data/assets/include/SDL2/SDL_test_log.h +1 -1
- data/assets/include/SDL2/SDL_test_md5.h +1 -1
- data/assets/include/SDL2/SDL_test_memory.h +1 -1
- data/assets/include/SDL2/SDL_test_random.h +2 -2
- data/assets/include/SDL2/SDL_thread.h +226 -128
- data/assets/include/SDL2/SDL_timer.h +129 -22
- data/assets/include/SDL2/SDL_touch.h +48 -8
- data/assets/include/SDL2/SDL_ttf.h +102 -9
- data/assets/include/SDL2/SDL_types.h +1 -1
- data/assets/include/SDL2/SDL_version.h +72 -46
- data/assets/include/SDL2/SDL_video.h +1266 -460
- data/assets/include/SDL2/SDL_vulkan.h +100 -161
- data/assets/include/SDL2/begin_code.h +22 -1
- data/assets/include/SDL2/close_code.h +1 -1
- data/assets/include/mrbconf.h +234 -0
- data/assets/include/mruby/array.h +317 -0
- data/assets/include/mruby/boxing_nan.h +130 -0
- data/assets/include/mruby/boxing_no.h +58 -0
- data/assets/include/mruby/boxing_word.h +205 -0
- data/assets/include/mruby/class.h +108 -0
- data/assets/include/mruby/common.h +92 -0
- data/assets/include/mruby/compile.h +210 -0
- data/assets/include/mruby/data.h +76 -0
- data/assets/include/mruby/debug.h +66 -0
- data/assets/include/mruby/dump.h +158 -0
- data/assets/include/mruby/endian.h +44 -0
- data/assets/include/mruby/error.h +137 -0
- data/assets/include/mruby/gc.h +92 -0
- data/assets/include/mruby/hash.h +242 -0
- data/assets/include/mruby/irep.h +147 -0
- data/assets/include/mruby/istruct.h +50 -0
- data/assets/include/mruby/khash.h +284 -0
- data/assets/include/mruby/numeric.h +169 -0
- data/assets/include/mruby/object.h +43 -0
- data/assets/include/mruby/opcode.h +43 -0
- data/assets/include/mruby/ops.h +122 -0
- data/assets/include/mruby/presym/disable.h +70 -0
- data/assets/include/mruby/presym/enable.h +37 -0
- data/assets/include/mruby/presym/scanning.h +73 -0
- data/assets/include/mruby/presym.h +40 -0
- data/assets/include/mruby/proc.h +209 -0
- data/assets/include/mruby/range.h +79 -0
- data/assets/include/mruby/re.h +16 -0
- data/assets/include/mruby/string.h +469 -0
- data/assets/include/mruby/throw.h +66 -0
- data/assets/include/mruby/value.h +400 -0
- data/assets/include/mruby/variable.h +140 -0
- data/assets/include/mruby/version.h +143 -0
- data/assets/include/mruby.h +1444 -0
- data/assets/macos/universal/bin/mrbc +0 -0
- data/assets/macos/universal/lib/libFLAC.a +0 -0
- data/assets/macos/universal/lib/libSDL2.a +0 -0
- data/assets/macos/universal/lib/libSDL2_image.a +0 -0
- data/assets/macos/{lib → universal/lib}/libSDL2_mixer.a +0 -0
- data/assets/macos/universal/lib/libSDL2_ttf.a +0 -0
- data/assets/macos/universal/lib/libfreetype.a +0 -0
- data/assets/macos/universal/lib/libgraphite2.a +0 -0
- data/assets/macos/universal/lib/libharfbuzz.a +0 -0
- data/assets/macos/universal/lib/libjpeg.a +0 -0
- data/assets/macos/{lib → universal/lib}/libmodplug.a +0 -0
- data/assets/macos/{lib → universal/lib}/libmpg123.a +0 -0
- data/assets/{mingw/lib/libSDL2.a → macos/universal/lib/libmruby.a} +0 -0
- data/assets/macos/{lib → universal/lib}/libogg.a +0 -0
- data/assets/macos/universal/lib/libpng16.a +0 -0
- data/assets/macos/universal/lib/libtiff.a +0 -0
- data/assets/macos/universal/lib/libvorbis.a +0 -0
- data/assets/macos/universal/lib/libvorbisfile.a +0 -0
- data/assets/macos/universal/lib/libwebp.a +0 -0
- data/assets/test_media/README.md +3 -0
- data/assets/test_media/bitstream_vera/COPYRIGHT.txt +124 -0
- data/assets/test_media/bitstream_vera/vera.ttf +0 -0
- data/assets/test_media/boom.png +0 -0
- data/assets/test_media/coin.png +0 -0
- data/assets/test_media/colors.png +0 -0
- data/assets/test_media/controller.png +0 -0
- data/assets/test_media/dial.wav +0 -0
- data/assets/test_media/hero.png +0 -0
- data/assets/test_media/image.bmp +0 -0
- data/assets/test_media/image.jpg +0 -0
- data/assets/test_media/image.png +0 -0
- data/assets/test_media/music.flac +0 -0
- data/assets/test_media/music.mp3 +0 -0
- data/assets/test_media/music.ogg +0 -0
- data/assets/test_media/music.wav +0 -0
- data/assets/test_media/originals/boom.pxm +0 -0
- data/assets/test_media/originals/coin.pxm +0 -0
- data/assets/test_media/originals/controller.sketch +0 -0
- data/assets/test_media/originals/hero.pxm +0 -0
- data/assets/test_media/originals/image.pxm +0 -0
- data/assets/test_media/originals/music.caf +0 -0
- data/assets/test_media/originals/texture_atlas.pxm +0 -0
- data/assets/test_media/rondo_alla_turka.ogg +0 -0
- data/assets/test_media/sound.flac +0 -0
- data/assets/test_media/sound.mp3 +0 -0
- data/assets/test_media/sound.ogg +0 -0
- data/assets/test_media/sound.wav +0 -0
- data/assets/test_media/sprite_sheet.png +0 -0
- data/assets/test_media/texture_atlas.png +0 -0
- data/assets/wasm/build_config.rb +13 -0
- data/assets/wasm/libmruby.a +0 -0
- data/assets/wasm/template.html +17 -0
- data/assets/windows/glew/README.md +10 -0
- data/assets/windows/glew/glew.h +23686 -0
- data/assets/{mingw/lib → windows/glew}/libglew32.a +0 -0
- data/assets/windows/mingw-w64-x86_64/bin/mrbc.exe +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libFLAC.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libLerc.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libSDL2.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libSDL2_image.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libSDL2_mixer.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libSDL2_ttf.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libbrotlicommon.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libbrotlidec.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libbz2.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libdeflate.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libfreetype.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libglew32.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libgraphite2.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libharfbuzz.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libjbig.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libjpeg.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/liblzma.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libmodplug.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libmpg123.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libmruby.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libogg.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libopus.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libopusfile.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libpng16.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libsndfile.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libssp.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libstdc++.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libtiff.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libvorbis.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libvorbisfile.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libwebp.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libz.a +0 -0
- data/assets/windows/mingw-w64-x86_64/lib/libzstd.a +0 -0
- data/assets/{ios → xcode/ios}/Assets.xcassets/AppIcon.appiconset/Contents.json +0 -0
- data/assets/{ios → xcode/ios}/Assets.xcassets/Contents.json +0 -0
- data/assets/{ios → xcode/ios}/Base.lproj/LaunchScreen.storyboard +0 -0
- data/assets/{ios → xcode/ios}/Info.plist +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mrbconf.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/array.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/boxing_nan.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/boxing_no.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/boxing_word.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/class.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/common.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/compile.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/data.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/debug.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/dump.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/error.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/gc.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/hash.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/irep.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/istruct.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/khash.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/numeric.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/object.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/opcode.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/ops.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/proc.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/range.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/re.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/string.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/throw.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/value.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/variable.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby/version.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Headers/mruby.h +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/Info.plist +0 -0
- data/assets/{ios → xcode/ios}/MRuby.framework/MRuby +0 -0
- data/assets/{ios → xcode/ios}/MyApp.xcodeproj/project.pbxproj +0 -0
- data/assets/{ios → xcode/ios}/MyApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata +0 -0
- data/assets/{ios → xcode/ios}/MyApp.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -0
- data/assets/{ios → xcode/ios}/MyApp.xcodeproj/project.xcworkspace/xcshareddata/MyApp.xcscmblueprint +0 -0
- data/assets/{ios → xcode/ios}/main.c +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Back.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Back.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Front.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Front.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Middle.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Large.imagestack/Middle.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Back.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Back.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Front.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Front.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Middle.imagestacklayer/Content.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/App Icon - Small.imagestack/Middle.imagestacklayer/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/Top Shelf Image Wide.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/App Icon & Top Shelf Image.brandassets/Top Shelf Image.imageset/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Assets.xcassets/LaunchImage.launchimage/Contents.json +0 -0
- data/assets/{tvos → xcode/tvos}/Info.plist +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mrbconf.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/array.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/boxing_nan.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/boxing_no.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/boxing_word.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/class.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/common.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/compile.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/data.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/debug.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/dump.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/error.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/gc.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/hash.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/irep.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/istruct.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/khash.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/numeric.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/object.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/opcode.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/ops.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/proc.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/range.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/re.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/string.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/throw.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/value.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/variable.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby/version.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Headers/mruby.h +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/Info.plist +0 -0
- data/assets/{tvos → xcode/tvos}/MRuby.framework/MRuby +0 -0
- data/assets/{tvos → xcode/tvos}/MyApp.xcodeproj/project.pbxproj +0 -0
- data/assets/{tvos → xcode/tvos}/MyApp.xcodeproj/project.xcworkspace/contents.xcworkspacedata +0 -0
- data/assets/{tvos → xcode/tvos}/MyApp.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +0 -0
- data/assets/{tvos → xcode/tvos}/MyApp.xcodeproj/project.xcworkspace/xcshareddata/MyApp.xcscmblueprint +0 -0
- data/assets/{tvos → xcode/tvos}/main.c +0 -0
- data/bin/ruby2d +3 -4
- data/ext/ruby2d/extconf.rb +39 -25
- data/ext/ruby2d/gl.c +1 -1
- data/ext/ruby2d/gl3.c +0 -1
- data/ext/ruby2d/gles.c +137 -84
- data/ext/ruby2d/ruby2d.c +126 -32
- data/ext/ruby2d/ruby2d.h +53 -6
- data/ext/ruby2d/text.c +14 -1
- data/ext/ruby2d/window.c +253 -215
- data/lib/ruby2d/cli/build.rb +237 -59
- data/lib/ruby2d/cli/colorize.rb +5 -4
- data/lib/ruby2d/cli/platform.rb +17 -0
- data/lib/ruby2d/font.rb +7 -1
- data/lib/ruby2d/sprite.rb +7 -2
- data/lib/ruby2d/text.rb +1 -3
- data/lib/ruby2d/texture.rb +21 -21
- data/lib/ruby2d/tileset.rb +34 -33
- data/lib/ruby2d/version.rb +1 -1
- data/lib/ruby2d/vertices.rb +11 -6
- data/lib/ruby2d.rb +14 -20
- metadata +246 -152
- data/assets/README.md +0 -22
- data/assets/Rakefile +0 -85
- data/assets/macos/lib/libFLAC.a +0 -0
- data/assets/macos/lib/libSDL2.a +0 -0
- data/assets/macos/lib/libSDL2_image.a +0 -0
- data/assets/macos/lib/libSDL2_ttf.a +0 -0
- data/assets/macos/lib/libfreetype.a +0 -0
- data/assets/macos/lib/libjpeg.a +0 -0
- data/assets/macos/lib/libpng16.a +0 -0
- data/assets/macos/lib/libtiff.a +0 -0
- data/assets/macos/lib/libvorbis.a +0 -0
- data/assets/macos/lib/libvorbisfile.a +0 -0
- data/assets/macos/lib/libwebp.a +0 -0
- data/assets/mingw/bin/SDL2.dll +0 -0
- data/assets/mingw/bin/SDL2_image.dll +0 -0
- data/assets/mingw/bin/SDL2_mixer.dll +0 -0
- data/assets/mingw/bin/SDL2_ttf.dll +0 -0
- data/assets/mingw/bin/glew32.dll +0 -0
- data/assets/mingw/bin/libFLAC-8.dll +0 -0
- data/assets/mingw/bin/libfreetype-6.dll +0 -0
- data/assets/mingw/bin/libjpeg-9.dll +0 -0
- data/assets/mingw/bin/libmodplug-1.dll +0 -0
- data/assets/mingw/bin/libmpg123-0.dll +0 -0
- data/assets/mingw/bin/libogg-0.dll +0 -0
- data/assets/mingw/bin/libopus-0.dll +0 -0
- data/assets/mingw/bin/libopusfile-0.dll +0 -0
- data/assets/mingw/bin/libpng16-16.dll +0 -0
- data/assets/mingw/bin/libtiff-5.dll +0 -0
- data/assets/mingw/bin/libvorbis-0.dll +0 -0
- data/assets/mingw/bin/libvorbisfile-3.dll +0 -0
- data/assets/mingw/bin/libwebp-7.dll +0 -0
- data/assets/mingw/bin/zlib1.dll +0 -0
- data/assets/mingw/lib/libSDL2.dll.a +0 -0
- data/assets/mingw/lib/libSDL2_image.a +0 -0
- data/assets/mingw/lib/libSDL2_image.dll.a +0 -0
- data/assets/mingw/lib/libSDL2_mixer.a +0 -0
- data/assets/mingw/lib/libSDL2_mixer.dll.a +0 -0
- data/assets/mingw/lib/libSDL2_test.a +0 -0
- data/assets/mingw/lib/libSDL2_ttf.a +0 -0
- data/assets/mingw/lib/libSDL2_ttf.dll.a +0 -0
- data/assets/mingw/lib/libSDL2main.a +0 -0
- data/assets/mingw/lib/libglew32.dll.a +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
2
|
Simple DirectMedia Layer
|
|
3
|
-
Copyright (C) 1997-
|
|
3
|
+
Copyright (C) 1997-2022 Sam Lantinga <slouken@libsdl.org>
|
|
4
4
|
|
|
5
5
|
This software is provided 'as-is', without any express or implied
|
|
6
6
|
warranty. In no event will the authors be held liable for any damages
|
|
@@ -112,90 +112,283 @@ typedef enum
|
|
|
112
112
|
|
|
113
113
|
|
|
114
114
|
/**
|
|
115
|
-
*
|
|
115
|
+
* Set the priority of all log categories.
|
|
116
|
+
*
|
|
117
|
+
* \param priority the SDL_LogPriority to assign
|
|
118
|
+
*
|
|
119
|
+
* \since This function is available since SDL 2.0.0.
|
|
120
|
+
*
|
|
121
|
+
* \sa SDL_LogSetPriority
|
|
116
122
|
*/
|
|
117
123
|
extern DECLSPEC void SDLCALL SDL_LogSetAllPriority(SDL_LogPriority priority);
|
|
118
124
|
|
|
119
125
|
/**
|
|
120
|
-
*
|
|
126
|
+
* Set the priority of a particular log category.
|
|
127
|
+
*
|
|
128
|
+
* \param category the category to assign a priority to
|
|
129
|
+
* \param priority the SDL_LogPriority to assign
|
|
130
|
+
*
|
|
131
|
+
* \since This function is available since SDL 2.0.0.
|
|
132
|
+
*
|
|
133
|
+
* \sa SDL_LogGetPriority
|
|
134
|
+
* \sa SDL_LogSetAllPriority
|
|
121
135
|
*/
|
|
122
136
|
extern DECLSPEC void SDLCALL SDL_LogSetPriority(int category,
|
|
123
137
|
SDL_LogPriority priority);
|
|
124
138
|
|
|
125
139
|
/**
|
|
126
|
-
*
|
|
140
|
+
* Get the priority of a particular log category.
|
|
141
|
+
*
|
|
142
|
+
* \param category the category to query
|
|
143
|
+
* \returns the SDL_LogPriority for the requested category
|
|
144
|
+
*
|
|
145
|
+
* \since This function is available since SDL 2.0.0.
|
|
146
|
+
*
|
|
147
|
+
* \sa SDL_LogSetPriority
|
|
127
148
|
*/
|
|
128
149
|
extern DECLSPEC SDL_LogPriority SDLCALL SDL_LogGetPriority(int category);
|
|
129
150
|
|
|
130
151
|
/**
|
|
131
|
-
*
|
|
152
|
+
* Reset all priorities to default.
|
|
132
153
|
*
|
|
133
|
-
*
|
|
154
|
+
* This is called by SDL_Quit().
|
|
155
|
+
*
|
|
156
|
+
* \since This function is available since SDL 2.0.0.
|
|
157
|
+
*
|
|
158
|
+
* \sa SDL_LogSetAllPriority
|
|
159
|
+
* \sa SDL_LogSetPriority
|
|
134
160
|
*/
|
|
135
161
|
extern DECLSPEC void SDLCALL SDL_LogResetPriorities(void);
|
|
136
162
|
|
|
137
163
|
/**
|
|
138
|
-
*
|
|
164
|
+
* Log a message with SDL_LOG_CATEGORY_APPLICATION and SDL_LOG_PRIORITY_INFO.
|
|
165
|
+
*
|
|
166
|
+
* = * \param fmt a printf() style message format string
|
|
167
|
+
*
|
|
168
|
+
* \param ... additional parameters matching % tokens in the `fmt` string, if
|
|
169
|
+
* any
|
|
170
|
+
*
|
|
171
|
+
* \since This function is available since SDL 2.0.0.
|
|
172
|
+
*
|
|
173
|
+
* \sa SDL_LogCritical
|
|
174
|
+
* \sa SDL_LogDebug
|
|
175
|
+
* \sa SDL_LogError
|
|
176
|
+
* \sa SDL_LogInfo
|
|
177
|
+
* \sa SDL_LogMessage
|
|
178
|
+
* \sa SDL_LogMessageV
|
|
179
|
+
* \sa SDL_LogVerbose
|
|
180
|
+
* \sa SDL_LogWarn
|
|
139
181
|
*/
|
|
140
182
|
extern DECLSPEC void SDLCALL SDL_Log(SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(1);
|
|
141
183
|
|
|
142
184
|
/**
|
|
143
|
-
*
|
|
185
|
+
* Log a message with SDL_LOG_PRIORITY_VERBOSE.
|
|
186
|
+
*
|
|
187
|
+
* \param category the category of the message
|
|
188
|
+
* \param fmt a printf() style message format string
|
|
189
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
190
|
+
* if any
|
|
191
|
+
*
|
|
192
|
+
* \since This function is available since SDL 2.0.0.
|
|
193
|
+
*
|
|
194
|
+
* \sa SDL_Log
|
|
195
|
+
* \sa SDL_LogCritical
|
|
196
|
+
* \sa SDL_LogDebug
|
|
197
|
+
* \sa SDL_LogError
|
|
198
|
+
* \sa SDL_LogInfo
|
|
199
|
+
* \sa SDL_LogMessage
|
|
200
|
+
* \sa SDL_LogMessageV
|
|
201
|
+
* \sa SDL_LogWarn
|
|
144
202
|
*/
|
|
145
203
|
extern DECLSPEC void SDLCALL SDL_LogVerbose(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
146
204
|
|
|
147
205
|
/**
|
|
148
|
-
*
|
|
206
|
+
* Log a message with SDL_LOG_PRIORITY_DEBUG.
|
|
207
|
+
*
|
|
208
|
+
* \param category the category of the message
|
|
209
|
+
* \param fmt a printf() style message format string
|
|
210
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
211
|
+
* if any
|
|
212
|
+
*
|
|
213
|
+
* \since This function is available since SDL 2.0.0.
|
|
214
|
+
*
|
|
215
|
+
* \sa SDL_Log
|
|
216
|
+
* \sa SDL_LogCritical
|
|
217
|
+
* \sa SDL_LogError
|
|
218
|
+
* \sa SDL_LogInfo
|
|
219
|
+
* \sa SDL_LogMessage
|
|
220
|
+
* \sa SDL_LogMessageV
|
|
221
|
+
* \sa SDL_LogVerbose
|
|
222
|
+
* \sa SDL_LogWarn
|
|
149
223
|
*/
|
|
150
224
|
extern DECLSPEC void SDLCALL SDL_LogDebug(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
151
225
|
|
|
152
226
|
/**
|
|
153
|
-
*
|
|
227
|
+
* Log a message with SDL_LOG_PRIORITY_INFO.
|
|
228
|
+
*
|
|
229
|
+
* \param category the category of the message
|
|
230
|
+
* \param fmt a printf() style message format string
|
|
231
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
232
|
+
* if any
|
|
233
|
+
*
|
|
234
|
+
* \since This function is available since SDL 2.0.0.
|
|
235
|
+
*
|
|
236
|
+
* \sa SDL_Log
|
|
237
|
+
* \sa SDL_LogCritical
|
|
238
|
+
* \sa SDL_LogDebug
|
|
239
|
+
* \sa SDL_LogError
|
|
240
|
+
* \sa SDL_LogMessage
|
|
241
|
+
* \sa SDL_LogMessageV
|
|
242
|
+
* \sa SDL_LogVerbose
|
|
243
|
+
* \sa SDL_LogWarn
|
|
154
244
|
*/
|
|
155
245
|
extern DECLSPEC void SDLCALL SDL_LogInfo(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
156
246
|
|
|
157
247
|
/**
|
|
158
|
-
*
|
|
248
|
+
* Log a message with SDL_LOG_PRIORITY_WARN.
|
|
249
|
+
*
|
|
250
|
+
* \param category the category of the message
|
|
251
|
+
* \param fmt a printf() style message format string
|
|
252
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
253
|
+
* if any
|
|
254
|
+
*
|
|
255
|
+
* \since This function is available since SDL 2.0.0.
|
|
256
|
+
*
|
|
257
|
+
* \sa SDL_Log
|
|
258
|
+
* \sa SDL_LogCritical
|
|
259
|
+
* \sa SDL_LogDebug
|
|
260
|
+
* \sa SDL_LogError
|
|
261
|
+
* \sa SDL_LogInfo
|
|
262
|
+
* \sa SDL_LogMessage
|
|
263
|
+
* \sa SDL_LogMessageV
|
|
264
|
+
* \sa SDL_LogVerbose
|
|
159
265
|
*/
|
|
160
266
|
extern DECLSPEC void SDLCALL SDL_LogWarn(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
161
267
|
|
|
162
268
|
/**
|
|
163
|
-
*
|
|
269
|
+
* Log a message with SDL_LOG_PRIORITY_ERROR.
|
|
270
|
+
*
|
|
271
|
+
* \param category the category of the message
|
|
272
|
+
* \param fmt a printf() style message format string
|
|
273
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
274
|
+
* if any
|
|
275
|
+
*
|
|
276
|
+
* \since This function is available since SDL 2.0.0.
|
|
277
|
+
*
|
|
278
|
+
* \sa SDL_Log
|
|
279
|
+
* \sa SDL_LogCritical
|
|
280
|
+
* \sa SDL_LogDebug
|
|
281
|
+
* \sa SDL_LogInfo
|
|
282
|
+
* \sa SDL_LogMessage
|
|
283
|
+
* \sa SDL_LogMessageV
|
|
284
|
+
* \sa SDL_LogVerbose
|
|
285
|
+
* \sa SDL_LogWarn
|
|
164
286
|
*/
|
|
165
287
|
extern DECLSPEC void SDLCALL SDL_LogError(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
166
288
|
|
|
167
289
|
/**
|
|
168
|
-
*
|
|
290
|
+
* Log a message with SDL_LOG_PRIORITY_CRITICAL.
|
|
291
|
+
*
|
|
292
|
+
* \param category the category of the message
|
|
293
|
+
* \param fmt a printf() style message format string
|
|
294
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
295
|
+
* if any
|
|
296
|
+
*
|
|
297
|
+
* \since This function is available since SDL 2.0.0.
|
|
298
|
+
*
|
|
299
|
+
* \sa SDL_Log
|
|
300
|
+
* \sa SDL_LogDebug
|
|
301
|
+
* \sa SDL_LogError
|
|
302
|
+
* \sa SDL_LogInfo
|
|
303
|
+
* \sa SDL_LogMessage
|
|
304
|
+
* \sa SDL_LogMessageV
|
|
305
|
+
* \sa SDL_LogVerbose
|
|
306
|
+
* \sa SDL_LogWarn
|
|
169
307
|
*/
|
|
170
308
|
extern DECLSPEC void SDLCALL SDL_LogCritical(int category, SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(2);
|
|
171
309
|
|
|
172
310
|
/**
|
|
173
|
-
*
|
|
311
|
+
* Log a message with the specified category and priority.
|
|
312
|
+
*
|
|
313
|
+
* \param category the category of the message
|
|
314
|
+
* \param priority the priority of the message
|
|
315
|
+
* \param fmt a printf() style message format string
|
|
316
|
+
* \param ... additional parameters matching % tokens in the **fmt** string,
|
|
317
|
+
* if any
|
|
318
|
+
*
|
|
319
|
+
* \since This function is available since SDL 2.0.0.
|
|
320
|
+
*
|
|
321
|
+
* \sa SDL_Log
|
|
322
|
+
* \sa SDL_LogCritical
|
|
323
|
+
* \sa SDL_LogDebug
|
|
324
|
+
* \sa SDL_LogError
|
|
325
|
+
* \sa SDL_LogInfo
|
|
326
|
+
* \sa SDL_LogMessageV
|
|
327
|
+
* \sa SDL_LogVerbose
|
|
328
|
+
* \sa SDL_LogWarn
|
|
174
329
|
*/
|
|
175
330
|
extern DECLSPEC void SDLCALL SDL_LogMessage(int category,
|
|
176
331
|
SDL_LogPriority priority,
|
|
177
332
|
SDL_PRINTF_FORMAT_STRING const char *fmt, ...) SDL_PRINTF_VARARG_FUNC(3);
|
|
178
333
|
|
|
179
334
|
/**
|
|
180
|
-
*
|
|
335
|
+
* Log a message with the specified category and priority.
|
|
336
|
+
*
|
|
337
|
+
* \param category the category of the message
|
|
338
|
+
* \param priority the priority of the message
|
|
339
|
+
* \param fmt a printf() style message format string
|
|
340
|
+
* \param ap a variable argument list
|
|
341
|
+
*
|
|
342
|
+
* \since This function is available since SDL 2.0.0.
|
|
343
|
+
*
|
|
344
|
+
* \sa SDL_Log
|
|
345
|
+
* \sa SDL_LogCritical
|
|
346
|
+
* \sa SDL_LogDebug
|
|
347
|
+
* \sa SDL_LogError
|
|
348
|
+
* \sa SDL_LogInfo
|
|
349
|
+
* \sa SDL_LogMessage
|
|
350
|
+
* \sa SDL_LogVerbose
|
|
351
|
+
* \sa SDL_LogWarn
|
|
181
352
|
*/
|
|
182
353
|
extern DECLSPEC void SDLCALL SDL_LogMessageV(int category,
|
|
183
354
|
SDL_LogPriority priority,
|
|
184
355
|
const char *fmt, va_list ap);
|
|
185
356
|
|
|
186
357
|
/**
|
|
187
|
-
*
|
|
358
|
+
* The prototype for the log output callback function.
|
|
359
|
+
*
|
|
360
|
+
* This function is called by SDL when there is new text to be logged.
|
|
361
|
+
*
|
|
362
|
+
* \param userdata what was passed as `userdata` to SDL_LogSetOutputFunction()
|
|
363
|
+
* \param category the category of the message
|
|
364
|
+
* \param priority the priority of the message
|
|
365
|
+
* \param message the message being output
|
|
188
366
|
*/
|
|
189
367
|
typedef void (SDLCALL *SDL_LogOutputFunction)(void *userdata, int category, SDL_LogPriority priority, const char *message);
|
|
190
368
|
|
|
191
369
|
/**
|
|
192
|
-
*
|
|
370
|
+
* Get the current log output function.
|
|
371
|
+
*
|
|
372
|
+
* \param callback an SDL_LogOutputFunction filled in with the current log
|
|
373
|
+
* callback
|
|
374
|
+
* \param userdata a pointer filled in with the pointer that is passed to
|
|
375
|
+
* `callback`
|
|
376
|
+
*
|
|
377
|
+
* \since This function is available since SDL 2.0.0.
|
|
378
|
+
*
|
|
379
|
+
* \sa SDL_LogSetOutputFunction
|
|
193
380
|
*/
|
|
194
381
|
extern DECLSPEC void SDLCALL SDL_LogGetOutputFunction(SDL_LogOutputFunction *callback, void **userdata);
|
|
195
382
|
|
|
196
383
|
/**
|
|
197
|
-
*
|
|
198
|
-
*
|
|
384
|
+
* Replace the default log output function with one of your own.
|
|
385
|
+
*
|
|
386
|
+
* \param callback an SDL_LogOutputFunction to call instead of the default
|
|
387
|
+
* \param userdata a pointer that is passed to `callback`
|
|
388
|
+
*
|
|
389
|
+
* \since This function is available since SDL 2.0.0.
|
|
390
|
+
*
|
|
391
|
+
* \sa SDL_LogGetOutputFunction
|
|
199
392
|
*/
|
|
200
393
|
extern DECLSPEC void SDLCALL SDL_LogSetOutputFunction(SDL_LogOutputFunction callback, void *userdata);
|
|
201
394
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
2
|
Simple DirectMedia Layer
|
|
3
|
-
Copyright (C) 1997-
|
|
3
|
+
Copyright (C) 1997-2022 Sam Lantinga <slouken@libsdl.org>
|
|
4
4
|
|
|
5
5
|
This software is provided 'as-is', without any express or implied
|
|
6
6
|
warranty. In no event will the authors be held liable for any damages
|
|
@@ -83,6 +83,15 @@
|
|
|
83
83
|
*/
|
|
84
84
|
#define SDL_MAIN_NEEDED
|
|
85
85
|
|
|
86
|
+
#elif defined(__PSP__)
|
|
87
|
+
/* On PSP SDL provides a main function that sets the module info,
|
|
88
|
+
activates the GPU and starts the thread required to be able to exit
|
|
89
|
+
the software.
|
|
90
|
+
|
|
91
|
+
If you provide this yourself, you may define SDL_MAIN_HANDLED
|
|
92
|
+
*/
|
|
93
|
+
#define SDL_MAIN_AVAILABLE
|
|
94
|
+
|
|
86
95
|
#endif
|
|
87
96
|
#endif /* SDL_MAIN_HANDLED */
|
|
88
97
|
|
|
@@ -122,20 +131,62 @@ extern SDLMAIN_DECLSPEC int SDL_main(int argc, char *argv[]);
|
|
|
122
131
|
|
|
123
132
|
|
|
124
133
|
/**
|
|
125
|
-
*
|
|
126
|
-
*
|
|
134
|
+
* Circumvent failure of SDL_Init() when not using SDL_main() as an entry
|
|
135
|
+
* point.
|
|
136
|
+
*
|
|
137
|
+
* This function is defined in SDL_main.h, along with the preprocessor rule to
|
|
138
|
+
* redefine main() as SDL_main(). Thus to ensure that your main() function
|
|
139
|
+
* will not be changed it is necessary to define SDL_MAIN_HANDLED before
|
|
140
|
+
* including SDL.h.
|
|
127
141
|
*
|
|
128
|
-
*
|
|
129
|
-
*
|
|
142
|
+
* \since This function is available since SDL 2.0.0.
|
|
143
|
+
*
|
|
144
|
+
* \sa SDL_Init
|
|
130
145
|
*/
|
|
131
146
|
extern DECLSPEC void SDLCALL SDL_SetMainReady(void);
|
|
132
147
|
|
|
133
148
|
#ifdef __WIN32__
|
|
134
149
|
|
|
135
150
|
/**
|
|
136
|
-
*
|
|
151
|
+
* Register a win32 window class for SDL's use.
|
|
152
|
+
*
|
|
153
|
+
* This can be called to set the application window class at startup. It is
|
|
154
|
+
* safe to call this multiple times, as long as every call is eventually
|
|
155
|
+
* paired with a call to SDL_UnregisterApp, but a second registration attempt
|
|
156
|
+
* while a previous registration is still active will be ignored, other than
|
|
157
|
+
* to increment a counter.
|
|
158
|
+
*
|
|
159
|
+
* Most applications do not need to, and should not, call this directly; SDL
|
|
160
|
+
* will call it when initializing the video subsystem.
|
|
161
|
+
*
|
|
162
|
+
* \param name the window class name, in UTF-8 encoding. If NULL, SDL
|
|
163
|
+
* currently uses "SDL_app" but this isn't guaranteed.
|
|
164
|
+
* \param style the value to use in WNDCLASSEX::style. If `name` is NULL, SDL
|
|
165
|
+
* currently uses `(CS_BYTEALIGNCLIENT | CS_OWNDC)` regardless of
|
|
166
|
+
* what is specified here.
|
|
167
|
+
* \param hInst the HINSTANCE to use in WNDCLASSEX::hInstance. If zero, SDL
|
|
168
|
+
* will use `GetModuleHandle(NULL)` instead.
|
|
169
|
+
* \returns 0 on success, -1 on error. SDL_GetError() may have details.
|
|
170
|
+
*
|
|
171
|
+
* \since This function is available since SDL 2.0.2.
|
|
172
|
+
*/
|
|
173
|
+
extern DECLSPEC int SDLCALL SDL_RegisterApp(const char *name, Uint32 style, void *hInst);
|
|
174
|
+
|
|
175
|
+
/**
|
|
176
|
+
* Deregister the win32 window class from an SDL_RegisterApp call.
|
|
177
|
+
*
|
|
178
|
+
* This can be called to undo the effects of SDL_RegisterApp.
|
|
179
|
+
*
|
|
180
|
+
* Most applications do not need to, and should not, call this directly; SDL
|
|
181
|
+
* will call it when deinitializing the video subsystem.
|
|
182
|
+
*
|
|
183
|
+
* It is safe to call this multiple times, as long as every call is eventually
|
|
184
|
+
* paired with a prior call to SDL_RegisterApp. The window class will only be
|
|
185
|
+
* deregistered when the registration counter in SDL_RegisterApp decrements to
|
|
186
|
+
* zero through calls to this function.
|
|
187
|
+
*
|
|
188
|
+
* \since This function is available since SDL 2.0.2.
|
|
137
189
|
*/
|
|
138
|
-
extern DECLSPEC int SDLCALL SDL_RegisterApp(char *name, Uint32 style, void *hInst);
|
|
139
190
|
extern DECLSPEC void SDLCALL SDL_UnregisterApp(void);
|
|
140
191
|
|
|
141
192
|
#endif /* __WIN32__ */
|
|
@@ -144,12 +195,14 @@ extern DECLSPEC void SDLCALL SDL_UnregisterApp(void);
|
|
|
144
195
|
#ifdef __WINRT__
|
|
145
196
|
|
|
146
197
|
/**
|
|
147
|
-
*
|
|
198
|
+
* Initialize and launch an SDL/WinRT application.
|
|
148
199
|
*
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
*
|
|
152
|
-
*
|
|
200
|
+
* \param mainFunction the SDL app's C-style main(), an SDL_main_func
|
|
201
|
+
* \param reserved reserved for future use; should be NULL
|
|
202
|
+
* \returns 0 on success or -1 on failure; call SDL_GetError() to retrieve
|
|
203
|
+
* more information on the failure.
|
|
204
|
+
*
|
|
205
|
+
* \since This function is available since SDL 2.0.3.
|
|
153
206
|
*/
|
|
154
207
|
extern DECLSPEC int SDLCALL SDL_WinRTRunApp(SDL_main_func mainFunction, void * reserved);
|
|
155
208
|
|
|
@@ -158,12 +211,14 @@ extern DECLSPEC int SDLCALL SDL_WinRTRunApp(SDL_main_func mainFunction, void * r
|
|
|
158
211
|
#if defined(__IPHONEOS__)
|
|
159
212
|
|
|
160
213
|
/**
|
|
161
|
-
*
|
|
214
|
+
* Initializes and launches an SDL application.
|
|
215
|
+
*
|
|
216
|
+
* \param argc The argc parameter from the application's main() function
|
|
217
|
+
* \param argv The argv parameter from the application's main() function
|
|
218
|
+
* \param mainFunction The SDL app's C-style main(), an SDL_main_func
|
|
219
|
+
* \return the return value from mainFunction
|
|
162
220
|
*
|
|
163
|
-
*
|
|
164
|
-
* \param argv The argv parameter from the application's main() function
|
|
165
|
-
* \param mainFunction The SDL app's C-style main().
|
|
166
|
-
* \return the return value from mainFunction
|
|
221
|
+
* \since This function is available since SDL 2.0.10.
|
|
167
222
|
*/
|
|
168
223
|
extern DECLSPEC int SDLCALL SDL_UIKitRunApp(int argc, char *argv[], SDL_main_func mainFunction);
|
|
169
224
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*
|
|
2
2
|
Simple DirectMedia Layer
|
|
3
|
-
Copyright (C) 1997-
|
|
3
|
+
Copyright (C) 1997-2022 Sam Lantinga <slouken@libsdl.org>
|
|
4
4
|
|
|
5
5
|
This software is provided 'as-is', without any express or implied
|
|
6
6
|
warranty. In no event will the authors be held liable for any damages
|
|
@@ -32,7 +32,7 @@ extern "C" {
|
|
|
32
32
|
#endif
|
|
33
33
|
|
|
34
34
|
/**
|
|
35
|
-
*
|
|
35
|
+
* SDL_MessageBox flags. If supported will display warning icon, etc.
|
|
36
36
|
*/
|
|
37
37
|
typedef enum
|
|
38
38
|
{
|
|
@@ -44,7 +44,7 @@ typedef enum
|
|
|
44
44
|
} SDL_MessageBoxFlags;
|
|
45
45
|
|
|
46
46
|
/**
|
|
47
|
-
*
|
|
47
|
+
* Flags for SDL_MessageBoxButtonData.
|
|
48
48
|
*/
|
|
49
49
|
typedef enum
|
|
50
50
|
{
|
|
@@ -53,7 +53,7 @@ typedef enum
|
|
|
53
53
|
} SDL_MessageBoxButtonFlags;
|
|
54
54
|
|
|
55
55
|
/**
|
|
56
|
-
*
|
|
56
|
+
* Individual button data.
|
|
57
57
|
*/
|
|
58
58
|
typedef struct
|
|
59
59
|
{
|
|
@@ -63,7 +63,7 @@ typedef struct
|
|
|
63
63
|
} SDL_MessageBoxButtonData;
|
|
64
64
|
|
|
65
65
|
/**
|
|
66
|
-
*
|
|
66
|
+
* RGB value used in a message box color scheme
|
|
67
67
|
*/
|
|
68
68
|
typedef struct
|
|
69
69
|
{
|
|
@@ -81,7 +81,7 @@ typedef enum
|
|
|
81
81
|
} SDL_MessageBoxColorType;
|
|
82
82
|
|
|
83
83
|
/**
|
|
84
|
-
*
|
|
84
|
+
* A set of colors to use for message box dialogs
|
|
85
85
|
*/
|
|
86
86
|
typedef struct
|
|
87
87
|
{
|
|
@@ -89,7 +89,7 @@ typedef struct
|
|
|
89
89
|
} SDL_MessageBoxColorScheme;
|
|
90
90
|
|
|
91
91
|
/**
|
|
92
|
-
*
|
|
92
|
+
* MessageBox structure containing title, text, window, etc.
|
|
93
93
|
*/
|
|
94
94
|
typedef struct
|
|
95
95
|
{
|
|
@@ -105,32 +105,79 @@ typedef struct
|
|
|
105
105
|
} SDL_MessageBoxData;
|
|
106
106
|
|
|
107
107
|
/**
|
|
108
|
-
*
|
|
108
|
+
* Create a modal message box.
|
|
109
109
|
*
|
|
110
|
-
*
|
|
111
|
-
*
|
|
110
|
+
* If your needs aren't complex, it might be easier to use
|
|
111
|
+
* SDL_ShowSimpleMessageBox.
|
|
112
112
|
*
|
|
113
|
-
*
|
|
114
|
-
*
|
|
113
|
+
* This function should be called on the thread that created the parent
|
|
114
|
+
* window, or on the main thread if the messagebox has no parent. It will
|
|
115
|
+
* block execution of that thread until the user clicks a button or closes the
|
|
116
|
+
* messagebox.
|
|
115
117
|
*
|
|
116
|
-
*
|
|
117
|
-
*
|
|
118
|
-
*
|
|
119
|
-
*
|
|
118
|
+
* This function may be called at any time, even before SDL_Init(). This makes
|
|
119
|
+
* it useful for reporting errors like a failure to create a renderer or
|
|
120
|
+
* OpenGL context.
|
|
121
|
+
*
|
|
122
|
+
* On X11, SDL rolls its own dialog box with X11 primitives instead of a
|
|
123
|
+
* formal toolkit like GTK+ or Qt.
|
|
124
|
+
*
|
|
125
|
+
* Note that if SDL_Init() would fail because there isn't any available video
|
|
126
|
+
* target, this function is likely to fail for the same reasons. If this is a
|
|
127
|
+
* concern, check the return value from this function and fall back to writing
|
|
128
|
+
* to stderr if you can.
|
|
129
|
+
*
|
|
130
|
+
* \param messageboxdata the SDL_MessageBoxData structure with title, text and
|
|
131
|
+
* other options
|
|
132
|
+
* \param buttonid the pointer to which user id of hit button should be copied
|
|
133
|
+
* \returns 0 on success or a negative error code on failure; call
|
|
134
|
+
* SDL_GetError() for more information.
|
|
135
|
+
*
|
|
136
|
+
* \since This function is available since SDL 2.0.0.
|
|
137
|
+
*
|
|
138
|
+
* \sa SDL_ShowSimpleMessageBox
|
|
120
139
|
*/
|
|
121
140
|
extern DECLSPEC int SDLCALL SDL_ShowMessageBox(const SDL_MessageBoxData *messageboxdata, int *buttonid);
|
|
122
141
|
|
|
123
142
|
/**
|
|
124
|
-
*
|
|
143
|
+
* Display a simple modal message box.
|
|
144
|
+
*
|
|
145
|
+
* If your needs aren't complex, this function is preferred over
|
|
146
|
+
* SDL_ShowMessageBox.
|
|
147
|
+
*
|
|
148
|
+
* `flags` may be any of the following:
|
|
149
|
+
*
|
|
150
|
+
* - `SDL_MESSAGEBOX_ERROR`: error dialog
|
|
151
|
+
* - `SDL_MESSAGEBOX_WARNING`: warning dialog
|
|
152
|
+
* - `SDL_MESSAGEBOX_INFORMATION`: informational dialog
|
|
153
|
+
*
|
|
154
|
+
* This function should be called on the thread that created the parent
|
|
155
|
+
* window, or on the main thread if the messagebox has no parent. It will
|
|
156
|
+
* block execution of that thread until the user clicks a button or closes the
|
|
157
|
+
* messagebox.
|
|
158
|
+
*
|
|
159
|
+
* This function may be called at any time, even before SDL_Init(). This makes
|
|
160
|
+
* it useful for reporting errors like a failure to create a renderer or
|
|
161
|
+
* OpenGL context.
|
|
162
|
+
*
|
|
163
|
+
* On X11, SDL rolls its own dialog box with X11 primitives instead of a
|
|
164
|
+
* formal toolkit like GTK+ or Qt.
|
|
165
|
+
*
|
|
166
|
+
* Note that if SDL_Init() would fail because there isn't any available video
|
|
167
|
+
* target, this function is likely to fail for the same reasons. If this is a
|
|
168
|
+
* concern, check the return value from this function and fall back to writing
|
|
169
|
+
* to stderr if you can.
|
|
125
170
|
*
|
|
126
|
-
*
|
|
127
|
-
*
|
|
128
|
-
*
|
|
129
|
-
*
|
|
171
|
+
* \param flags an SDL_MessageBoxFlags value
|
|
172
|
+
* \param title UTF-8 title text
|
|
173
|
+
* \param message UTF-8 message text
|
|
174
|
+
* \param window the parent window, or NULL for no parent
|
|
175
|
+
* \returns 0 on success or a negative error code on failure; call
|
|
176
|
+
* SDL_GetError() for more information.
|
|
130
177
|
*
|
|
131
|
-
*
|
|
178
|
+
* \since This function is available since SDL 2.0.0.
|
|
132
179
|
*
|
|
133
|
-
*
|
|
180
|
+
* \sa SDL_ShowMessageBox
|
|
134
181
|
*/
|
|
135
182
|
extern DECLSPEC int SDLCALL SDL_ShowSimpleMessageBox(Uint32 flags, const char *title, const char *message, SDL_Window *window);
|
|
136
183
|
|