Function SDL_GetDesktopDisplayMode
pub unsafe extern "C" fn SDL_GetDesktopDisplayMode(
displayID: u32,
) -> *const SDL_DisplayMode
Available on crate feature
dep_sdl3
only.Expand description
Get information about the desktop’s display mode.
There’s a difference between this function and SDL_GetCurrentDisplayMode()
when SDL runs fullscreen and has changed the resolution. In that case this
function will return the previous native display mode, and not the current
display mode.
§Parameters
displayID
: the instance ID of the display to query.
§Return value
Returns a pointer to the desktop display mode or NULL on failure; call
SDL_GetError()
for more information.
§Thread safety
This function should only be called on the main thread.
§Availability
This function is available since SDL 3.2.0.