Function Display.getClosestDisplayMode

Wraps SDL_GetClosestDisplayMode which gets the closest display mode of the display to the desired mode

DisplayMode getClosestDisplayMode (
  DisplayMode desiredMode
) @trusted const;

Parameters

NameDescription
desiredMode the desired dsdl.DisplayMode

Returns

the closest available dsdl.DisplayMode of the display

Throws

dsdl.SDLException if failed to get the closest display mode