Commit Graph

54 Commits (5baed331f1dc9bc180d9730c0083d4395bb75f30)

Author SHA1 Message Date
Sam Lantinga cc0296c934 SDL API renaming: SDL_surface.h
Fixes https://github.com/libsdl-org/SDL/issues/6884
2022-12-27 06:36:39 -08:00
Sam Lantinga 0d54115235 SDL API renaming: SDL_render.h
Fixes https://github.com/libsdl-org/SDL/issues/6883
2022-12-27 06:21:13 -08:00
Sam Lantinga fc478c1bc0 SDL API renaming: SDL_joystick.h
Fixes https://github.com/libsdl-org/SDL/issues/6881
2022-12-27 05:50:46 -08:00
Frank Praznik abdfa809db Prepend key modifier enum values with 'SDL_' 2022-12-23 20:35:49 -08:00
Sam Lantinga 5a45d2e58b Updated Xcode project for SDL_main as a header-only library 2022-12-15 10:53:44 -08:00
Daniel Gibson 8e0693c982 Make iOS/tvOS (uikit) SDL_main header-only
Also adjusted iOS demo's includes to <SDL3/..> and explicit SDL_main.h

untested, I don't have Xcode (or a Mac, for that matter)

The xcode projects (for both Xcode-iOS/ and Xcode/) will probably
have to be adjusted for the SDL_main changes to work, but now at least
the iOS demo source should work as is :)
2022-12-15 08:01:01 -08:00
Ryan C. Gordon 5a2d0b69c8
render: Remove SDL_GetRenderDriverInfo and change SDL_CreateRenderer.
Fixes #6625.
2022-12-13 23:27:35 -05:00
Sylvain Becker 932f61348d
Remove mask versions of SDL_CreateRGBSurface* #6701 (#6711)
* Rename SDL_CreateRGBSurface{,From} to SDL_CreateSurface{,From}, which now takes a format parameter
2022-12-01 08:04:02 -08:00
Sylvain Becker fc4fc5295f
Remove depth field from SDL_CreateRGBSurfaceWithFormat and SDL_Create… (#6685)
* Remove depth field from SDL_CreateRGBSurfaceWithFormat and SDL_CreateRGBSurfaceWithFormatFrom
* Removed unused 'flags' parameter from SDL_CreateRGBSurface and SDL_CreateRGBSurfaceWithFormat
* Removed unused 'flags' parameter from SDL_ConvertSurface and SDL_ConvertSurfaceFormat
2022-11-29 09:40:09 -08:00
Sylvain Becker 6a2200823c
Cleanup add brace (#6545)
* Add braces after if conditions

* More add braces after if conditions

* Add braces after while() conditions

* Fix compilation because of macro being modified

* Add braces to for loop

* Add braces after if/goto

* Move comments up

* Remove extra () in the 'return ...;' statements

* More remove extra () in the 'return ...;' statements

* More remove extra () in the 'return ...;' statements after merge

* Fix inconsistent patterns are xxx == NULL vs !xxx

* More "{}" for "if() break;"  and "if() continue;"

* More "{}" after if() short statement

* More "{}" after "if () return;" statement

* More fix inconsistent patterns are xxx == NULL vs !xxx

* Revert some modificaion on SDL_RLEaccel.c

* SDL_RLEaccel: no short statement

* Cleanup 'if' where the bracket is in a new line

* Cleanup 'while' where the bracket is in a new line

* Cleanup 'for' where the bracket is in a new line

* Cleanup 'else' where the bracket is in a new line
2022-11-27 08:38:43 -08:00
Sam Lantinga cc1f9eb983 Use Apple's nomenclature for macOS and iOS
Fixes https://github.com/libsdl-org/SDL/issues/6621
2022-11-25 16:00:06 -08:00
Sam Lantinga 2c4159b99a First pass at changing SDL 2.0 to SDL 3.0 2022-11-21 20:28:58 -08:00
Sylvain ce5da5d579
Don't compare pointer against '0', but NULL 2022-11-16 21:47:43 +01:00
Sam Lantinga 9f784b1887 The iOS and tvOS demos link SDL statically, not as a framework 2022-11-14 10:59:23 -08:00
Sam Lantinga 4471d22eb6 Updated iOS demos Xcode project 2022-09-28 01:10:23 -07:00
Sylvain c0029f01d7 remove 'free' in comment 2021-11-22 08:38:46 -08:00
Sylvain d31251b014 use SDL's functions version inplace of libc version 2021-11-22 08:38:46 -08:00
Sam Lantinga 19c129faba Added documentation that the UIApplicationSupportsIndirectInputEvents key must be set to true
in your application's Info.plist in order to get real Bluetooth mouse events.
2021-11-09 20:32:16 -08:00
Sam Lantinga a7e2e3a329 Fixed rendering in the iOS touch demo 2021-11-09 13:36:44 -08:00
Daniel Inkpen 344f018dfd Xcode-iOS Demos: Add CFBundleShortVersionString to Info.plist
Xcode 13.0 requires this key to be present in the Info.plist to be able to run the compiled code.
2021-09-29 16:39:31 -07:00
Sam Lantinga 1bd4b7fdf1 Updated iOS tests and demos for latest SDL linking requirements 2020-11-06 13:03:07 -08:00
Sam Lantinga dc60b975f3 Removed old iOS-only project and demos 2020-11-06 11:32:59 -08:00
Ozkan Sezer 09142eb715 fix permissions 2019-06-12 13:56:20 +03:00
Sam Lantinga aa80d279d3 Fix build with the 10.10 SDK 2019-06-11 08:33:30 -07:00
Sam Lantinga 30a5e90ba8 Fixed bug 4603 - The iOS Test Xcode project file needs to add the metal framework
Dominik Reichardt

Similar to bug #4088 the iOS test suite needs the metal framework to link. Same linking error in the final linking phase.
2019-06-08 14:29:05 -07:00
Ozkan Sezer 43d47f6b24 fix permissions 2018-11-15 07:20:02 +03:00
Sam Lantinga 2e348c1f59 Fixed bug 3193 - Dualshock 3's motion sensors overwrite analog stick
maxxus

The Dualshock 3's motion sensors don't seem to be reported by the call to EVIOCGBIT but they still send EV_ABS events.  Because they're not reported by EVIOCGBIT they're not assigned a proper axis ids and the default of 0 is used, which is the valid id for the left analog sticks left/right axis.
2018-11-14 13:37:22 -08:00
Sam Lantinga b08bdc4401 Don't build SDL_JOYSTICK_HIDAPI by default on iOS
If you enable this, you'll need to link with CoreBluetooth.framework and add something like this to your Info.plist:
<key>NSBluetoothPeripheralUsageDescription</key>
<string>MyApp would like to remain connected to nearby bluetooth Game Controllers and Game Pads even when you're not using the app.</string>
2018-10-26 09:27:31 -07:00
Ozkan Sezer f0549cc9c9 fix permissions 2018-10-23 09:10:02 +03:00
Sam Lantinga c4918db580 Add exception handling to Android hidapi. 2018-10-22 14:55:42 -07:00
Sam Lantinga 568068048f Fixed bug 4324 - Xcode 10 - more cleanup for macOS and iOS projects
Dominik Reichardt

Xcode warns about
"Traditional headermap style is no longer supported; please migrate to using separate headermaps and set 'ALWAYS_SEARCH_USER_PATHS' to NO."
Just doing the latter is enough to silence the warning without ill effects on compiling. This affects the macOS Xcode projects as well as the iOS projects. Definitely not a bug but an annoying warning that could go away.
2018-10-18 15:41:50 -07:00
Sam Lantinga 30def8e26b Fixed bug 4324 - Xcode 10 - more cleanup for macOS and iOS projects
Dominik Reichardt

Similar to bug/patch #4228, the iOS Demo Xcode project needs to add the CoreBluetooth framework.
2018-10-18 15:40:39 -07:00
Ozkan Sezer 41da7b79c0 ran 'chmod -x' on many files 2018-06-12 14:00:15 +03:00
Sam Lantinga 28602b1235 The volume was too high, clamp to SDL_MIX_MAXVOLUME 2017-09-22 11:15:57 -07:00
Sam Lantinga e8187a3f78 Updated iOS keyboard test to cover text input rect and orientation changes 2017-09-14 09:56:16 -07:00
Alex Szpakowski efc43a1d88 More cleanup of the iOS keyboard demo. 2017-08-15 23:00:54 -03:00
Alex Szpakowski a0a09f646c Improve iOS keyboard demo code a bit. 2017-08-15 22:53:57 -03:00
Philipp Wiesemann b84fe2c06b ios: Fixed math include in demos. 2017-05-25 23:01:59 +02:00
Philipp Wiesemann 37b49e6344 ios: Fixed compiler warnings about unused variables in demo. 2017-04-09 23:00:26 +02:00
Sam Lantinga b4e069e7f8 Fixed bug 3517 - Compiler warnings with gcc -Wstrict-prototypes
felix

Compiling even a simple SDL2 'hello world' program with gcc -Wstrict-prototypes (GCC 6.2.1) results in warnings like:

/usr/include/SDL2/SDL_gamecontroller.h:143:1: attention : function declaration isn't a prototype [-Wstrict-prototypes]
 extern DECLSPEC int SDLCALL SDL_GameControllerNumMappings();
 ^~~~~~

It seems there is a missing 'void' between the parentheses.
2016-12-26 02:12:21 -08:00
Philipp Wiesemann f662f68066 iOS: Updated demo README. 2016-10-09 20:30:49 +02:00
Philipp Wiesemann c2cb0b0ff4 iOS: Removed unused constant in demo. 2016-09-30 23:31:24 +02:00
Philipp Wiesemann 357c3dd746 iOS: Updated comment in demo. 2016-09-26 23:09:19 +02:00
Alex Szpakowski a8b033d7c4 Update the code for the iOS demos to handle modern devices. Fixes bug #3337 2016-09-25 00:23:35 -03:00
Alex Szpakowski 4209a1fd4c CoreAudio iOS/tvOS: Use AVFoundation instead of AudioSession. Fixes audio on tvOS.
Note that linking with AVFoundation is now required if you don't disable SDL_audio compilation on iOS and tvOS.
2016-09-15 19:59:57 -03:00
Alex Szpakowski f050576665 Initial Apple TV / tvOS support.
The Apple TV remote is currently exposed as a joystick with its touch surface treated as two axes. Key presses are also generated when its buttons and touch surface are used.

A new hint has been added to help deal with deciding whether to background the app when the remote's menu button is pressed: SDL_HINT_APPLE_TV_CONTROLLER_UI_EVENTS.
2016-09-13 22:18:06 -03:00
Philipp Wiesemann f3ca4e4d50 iOS: Fixed compiling demos on C89 compilers. 2016-04-01 21:14:49 +02:00
Philipp Wiesemann 62ebc527d0 iOS: Removed not needed SDL_WINDOW_SHOWN from rectangles demo. 2016-03-28 21:01:46 +02:00
Philipp Wiesemann bd60850b82 iOS: Fixed keyboard demo ignoring quit requests and window closing.
This also fixed a warning about an unused variable.
2016-03-28 21:01:26 +02:00
Philipp Wiesemann e9ca5b28a6 iOS: Replaced #import with #include in two demos.
This extension to C is not required here and made the demos less portable.
2016-03-27 22:26:34 +02:00