| Summary: | Android accelerometer z-axis incorrect | ||
|---|---|---|---|
| Product: | SDL | Reporter: | Alex Szpakowski <amaranth72> |
| Component: | joystick | Assignee: | Sam Lantinga <slouken> |
| Status: | RESOLVED FIXED | QA Contact: | Sam Lantinga <slouken> |
| Severity: | normal | ||
| Priority: | P2 | ||
| Version: | HG 2.0 | ||
| Hardware: | All | ||
| OS: | Android (All) | ||
|
Description
Alex Szpakowski
2016-09-17 01:06:33 UTC
Fixed, thanks! https://hg.libsdl.org/SDL/rev/c9e2cb97c17d Actually, Alex, can you confirm that with that change iOS and Android match for the same phone orientation? I don't have an Android device (or any Android development tools set up right now), so I can only test iOS. Some observations: - with my phone lying flat on a table and the screen facing up, acceleration due to gravity is -Z. It's +Z when the screen is facing down and lying flat. - holding it vertically in portrait, gravity is +Y. It's -Y when held upside down that way. - holding it vertically in landscape (with the top of the phone pointing to the right), gravity is +X. Pointing to the left it's -X. - the window's orientation doesn't affect the gravity values, only the device orientation does. |