sdlGetCurrentDisplayOrientation function

int sdlGetCurrentDisplayOrientation(
  1. int displayId
)

Get the orientation of a display.

\param displayID the instance ID of the display to query. \returns the SDL_DisplayOrientation enum value of the display, or SDL_ORIENTATION_UNKNOWN if it isn't available.

\threadsafety This function should only be called on the main thread.

\since This function is available since SDL 3.2.0.

\sa SDL_GetDisplays

extern SDL_DECLSPEC SDL_DisplayOrientation SDLCALL SDL_GetCurrentDisplayOrientation(SDL_DisplayID displayID)

Implementation

int sdlGetCurrentDisplayOrientation(int displayId) {
  final sdlGetCurrentDisplayOrientationLookupFunction = libSdl3
      .lookupFunction<
        Int32 Function(Uint32 displayId),
        int Function(int displayId)
      >('SDL_GetCurrentDisplayOrientation');
  return sdlGetCurrentDisplayOrientationLookupFunction(displayId);
}