| Summary: | Interval between SDL_SENSORUPDATE events for gyroscopes is too high | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Andrei Kortunov <andrei.kortunov> |
| Component: | events | Assignee: | Sam Lantinga <slouken> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | 2.0.9 | ||
| Hardware: | ARM | ||
| OS: | Android (All) | ||
|
Description
Andrei Kortunov
2020-03-22 18:02:28 UTC
In theory, the value can be controlled via ASensorEventQueue_setEventRate() function on Android, somewhere in the SDL_androidsensor.c: ASensorEventQueue_setEventRate(hwdata->eventqueue, hwdata->asensor, desiredDelay); It would be nice to have an optional argument for SDL_SensorOpen function to specify the update interval. To get the minimum supported interval (SENSOR_DELAY_FASTEST), it is possible to use the ASensor_getMinDelay(). Fixed, thanks! https://hg.libsdl.org/SDL/rev/06adf174772e |