Pierre Wendling
49c25b1daf
N3DS: Fix PrivateSensorUpdate call.
...
A new timestamp parameter was added in 2c51874
.
2022-10-10 08:50:59 -07:00
Pierre Wendling
392f3882d0
N3DS: Use SDL_Sensor instead of Joystick sensors.
2022-10-10 08:50:59 -07:00
Ozkan Sezer
77c7836c26
fix vita build failure after commit 2c518747b
2022-09-27 20:21:24 +03:00
Sam Lantinga
2c518747b9
Added microsecond timestamp to sensor values for PS4 and PS5 controllers using the HIDAPI driver
2022-09-27 09:56:49 -07:00
Sam Lantinga
e8c3ff56e0
Removed problematic call to ISensor_SetEventSink()
...
Fixes https://github.com/libsdl-org/SDL/issues/5288
2022-03-17 10:01:13 -07:00
Sam Lantinga
120c76c84b
Updated copyright for 2022
2022-01-03 09:40:21 -08:00
Sam Lantinga
3ba9276aff
Don't fail the sensor init if we couldn't create a sensor manager (i.e. we're running on Wine)
...
Fixes https://github.com/libsdl-org/SDL/issues/5031
2021-11-28 21:14:02 -08:00
Sam Lantinga
c2dd50a9a0
Fixed whitespace
2021-11-12 08:28:02 -08:00
Ivan Epifanov
e58a955e68
Deprecate dolcesdk
2021-03-08 09:07:12 -08:00
Ivan Epifanov
ca5e5d6154
VITASDK compatibility
2021-03-08 09:07:12 -08:00
Ivan Epifanov
7d89f09f74
ISO C90 fixes
2021-03-08 09:07:12 -08:00
Ivan Epifanov
6f7c7c557a
sensors corrections
2021-03-08 09:07:12 -08:00
Ivan Epifanov
6d85637786
Fix sensors
2021-03-08 09:07:12 -08:00
Ivan Epifanov
a1adc8a9d6
Add sensor support
2021-03-08 09:07:12 -08:00
Mathieu Eyraud
844d5e3ed3
Fix memory leak in ConnectSensor
...
'name' is leaked in case of error.
2021-02-21 16:46:20 -08:00
Ozkan Sezer
265a1cc97a
use WIN_StringToUTF8W instead of WIN_StringToUTF8 where needed ( #2 )
...
cf. bug #5435 .
- SDL_wasapi_win32.c (GetWasapiDeviceName): pwszVal is WCHAR*
- windows/SDL_sysfilesystem.c (SDL_GetBasePath, SDL_GetPrefPath)
- windows/SDL_sysurl.c (SDL_SYS_OpenURL): wurl is WCHAR*
- SDL_windowssensor.c (ConnectSensor): bstr_name is WCHAR*
- windows/SDL_systhread.c (SDL_SYS_SetupThread): strw is WCHAR*
2021-01-05 15:50:02 +03:00
Sam Lantinga
9130f7c377
Updated copyright for 2021
2021-01-02 10:25:38 -08:00
Sam Lantinga
cb36189692
Fixed bug 5235 - All internal sources should include SDL_assert.h
...
Ryan C. Gordon
We should really stick this in SDL_internal.h or something so it's always available.
2020-12-09 07:16:22 -08:00
Sam Lantinga
fcb21aa883
Added API for sensors on game controllers
...
Added support for the PS4 controller gyro and accelerometer on iOS and HIDAPI drivers
Also fixed an issue with the accelerometer on iOS having inverted axes
2020-11-17 10:30:20 -08:00
Ozkan Sezer
59795822d0
make SDL_SensorGetDeviceNonPortableType match its prototype.
2020-11-11 12:33:55 +03:00
Sam Lantinga
56622f9c92
Fixed bug 5126 - MinGW compile error SDL_windowssensor.c
...
Martin Gerhardy
SDL_windowssensor.c includes InitGuid.h - but it should be initguid.h
2020-06-17 10:09:07 -07:00
Ryan C. Gordon
a299fdd789
sensor: Fixed compiler warnings on mingw64.
2020-05-21 03:52:48 -04:00
Ryan C. Gordon
b4e76b58e7
sensor: Fix overaggressive search/replace. :)
2020-05-20 17:32:23 -04:00
Ryan C. Gordon
27c38eb22e
sensor: Correct fix for redefinition of various symbols.
2020-05-20 17:22:52 -04:00
Ryan C. Gordon
c9d358bce9
sensor: Fix build on various Windows compilers with various predefinitions.
2020-05-20 16:59:35 -04:00
Ryan C. Gordon
68777406e5
windows: Fix calls to CoCreateInstance() so last parameter is a LPVOID *.
2020-05-20 16:58:33 -04:00
Sam Lantinga
0f374b069b
Fixed build on older Visual Studio, enable new features on newer Visual Studio
2020-04-22 15:42:32 -07:00
Sam Lantinga
aba2792896
Added a Windows Gaming Input joystick driver
...
This driver supports the Razer Atrox Arcade Stick
Some of the quirks of this driver, inherent in Windows Gaming Input:
* There will never appear to be controllers connected at startup. You must support hot-plugging in order to see these controllers.
* You can't read the state of the guide button
* You can't get controller events in the background
2020-04-18 21:41:37 -07:00
Sam Lantinga
e9c94ac0b3
Fixed Windows accelerometer data units
2020-04-08 10:27:30 -07:00
Sam Lantinga
09f552639a
Fixed memory leak and removed debug code from Windows sensor implementation
2020-04-08 09:00:10 -07:00
Sam Lantinga
3180ba81af
First pass at Windows sensor implementation
2020-04-08 08:34:27 -07:00
Sam Lantinga
2c02b7410c
Fixed bug 5052 - Interval between SDL_SENSORUPDATE events for gyroscopes is too high
...
Andrei Kortunov
Hello. I try to implement an application for Android, which uses a new sensors API from 2.0.9 to control a camera rotation via built-in gyroscope, using the code from the test/testsensor.c as an example.
Gyroscope input itself works well, but an interval between SDL_SENSORUPDATE events is about 200ms (the SENSOR_DELAY_NORMAL, I believe), when I need the interval about 20-40ms (the SENSOR_DELAY_GAME or SENSOR_DELAY_FASTEST).
2020-03-23 12:10:05 -07:00
Sam Lantinga
a8780c6a28
Updated copyright date for 2020
2020-01-16 20:49:25 -08:00
Sylvain Becker
3ac67cf458
Fixed bug 4837 - Use after free in SDL_SensorUpdate (Thanks!)
2019-10-23 08:46:59 +02:00
Sylvain Becker
412ab7e1aa
Fixed bug 4829 - Sensor events incorrectly disabled
2019-10-18 14:23:37 +02:00
Sam Lantinga
5e13087b0f
Updated copyright for 2019
2019-01-04 22:01:14 -08:00
Sam Lantinga
b73703b9c6
Fixed bug 4391 - hid_enumerate() sometimes causes game to freeze for a few seconds
...
Daniel Gibson
Even though my game (dhewm3) doesn't use SDL_INIT_JOYSTICK, SDL_PumpEvent() calls SDL_JoystickUpdate() which ends up calling hid_enumerate() every three seconds, and sometimes on my Win7 box hid_enumerate() takes about 5 seconds, which causes the whole game to freeze for that time.
2018-11-19 21:17:00 -08:00
Micha? Janiszewski
91820998fc
Add and update include guards
...
Include guards in most changed files were missing, I added them keeping
the same style as other SDL files. In some cases I moved the include
guards around to be the first thing the header has to take advantage of
any possible improvements compiler may have for inclusion guards.
2018-10-28 21:36:48 +01:00
Sam Lantinga
7df0f4fdac
Fixed bug 4277 - warnings patch
...
Sylvain
Patch a few warnings when using:
-Wmissing-prototypes -Wdocumentation -Wdocumentation-unknown-command
They are automatically enabled with -Wall
2018-09-27 14:56:29 -07:00
Sam Lantinga
f225af0c1e
Added SDL_GetDisplayOrientation() to get the display orientation, and added a new event SDL_DISPLAYEVENT to notify the application when the orientation changes.
...
Documented the values returned by the accelerometer and gyroscope sensors
2018-08-22 21:48:28 -07:00
Sam Lantinga
c6647bf9c9
Added the iOS sensor implementation
2018-08-21 17:24:12 -07:00
Sam Lantinga
3e5dbc694a
Added a dummy sensor driver
2018-08-21 13:29:21 -07:00
Sam Lantinga
7c3040e08a
First pass on the new SDL sensor API
2018-08-21 12:11:34 -07:00