mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-27 23:19:11 +00:00
Added the concept of display natural orientation
Also renamed SDL_GetDisplayOrientation() SDL_GetDisplayCurrentOrientation() The natural orientation of the primary display is the frame of reference for accelerometer and gyro sensor readings.
This commit is contained in:
parent
8de6ce7e92
commit
e6d1ba2a17
20 changed files with 213 additions and 79 deletions
|
@ -2464,8 +2464,13 @@ void SDLTest_CommonDrawWindowInfo(SDL_Renderer *renderer, SDL_Window *window, fl
|
|||
textY += lineHeight;
|
||||
}
|
||||
|
||||
(void)SDL_snprintf(text, sizeof(text), "SDL_GetDisplayOrientation: ");
|
||||
SDLTest_PrintDisplayOrientation(text, sizeof(text), SDL_GetDisplayOrientation(windowDisplayID));
|
||||
(void)SDL_snprintf(text, sizeof(text), "SDL_GetDisplayNaturalOrientation: ");
|
||||
SDLTest_PrintDisplayOrientation(text, sizeof(text), SDL_GetDisplayNaturalOrientation(windowDisplayID));
|
||||
SDLTest_DrawString(renderer, 0.0f, textY, text);
|
||||
textY += lineHeight;
|
||||
|
||||
(void)SDL_snprintf(text, sizeof(text), "SDL_GetDisplayCurrentOrientation: ");
|
||||
SDLTest_PrintDisplayOrientation(text, sizeof(text), SDL_GetDisplayCurrentOrientation(windowDisplayID));
|
||||
SDLTest_DrawString(renderer, 0.0f, textY, text);
|
||||
textY += lineHeight;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue