SDL 3.0
SDL_DisplayMode Struct Reference

#include <SDL_video.h>

Data Fields

SDL_DisplayID displayID
 
SDL_PixelFormat format
 
int w
 
int h
 
float pixel_density
 
float refresh_rate
 
int refresh_rate_numerator
 
int refresh_rate_denominator
 
SDL_DisplayModeDatainternal
 

Detailed Description

The structure that defines a display mode.

Since
This struct is available since SDL 3.1.3.
See also
SDL_GetFullscreenDisplayModes
SDL_GetDesktopDisplayMode
SDL_GetCurrentDisplayMode
SDL_SetWindowFullscreenMode
SDL_GetWindowFullscreenMode

Definition at line 137 of file SDL_video.h.

Field Documentation

◆ displayID

SDL_DisplayID SDL_DisplayMode::displayID

the display this mode is associated with

Definition at line 139 of file SDL_video.h.

◆ format

SDL_PixelFormat SDL_DisplayMode::format

pixel format

Definition at line 140 of file SDL_video.h.

◆ h

int SDL_DisplayMode::h

height

Definition at line 142 of file SDL_video.h.

◆ internal

SDL_DisplayModeData* SDL_DisplayMode::internal

Private

Definition at line 148 of file SDL_video.h.

◆ pixel_density

float SDL_DisplayMode::pixel_density

scale converting size to pixels (e.g. a 1920x1080 mode with 2.0 scale would have 3840x2160 pixels)

Definition at line 143 of file SDL_video.h.

◆ refresh_rate

float SDL_DisplayMode::refresh_rate

refresh rate (or 0.0f for unspecified)

Definition at line 144 of file SDL_video.h.

◆ refresh_rate_denominator

int SDL_DisplayMode::refresh_rate_denominator

precise refresh rate denominator

Definition at line 146 of file SDL_video.h.

◆ refresh_rate_numerator

int SDL_DisplayMode::refresh_rate_numerator

precise refresh rate numerator (or 0 for unspecified)

Definition at line 145 of file SDL_video.h.

◆ w

int SDL_DisplayMode::w

width

Definition at line 141 of file SDL_video.h.


The documentation for this struct was generated from the following file: