GREM 3.12.0
Game/Rendering Engine Modules for C++
Loading...
Searching...
No Matches
grem::graphics::DisplayMode Class Reference

Information about a specific display mode available to a Display. More...

#include <GREM/graphics/Display.hpp>

Public Member Functions

Extent2D getSize () const noexcept
 Get the size of the display mode.
float getPixelDensity () const noexcept
 Get the pixel density of the display mode.
float getRefreshRate () const noexcept
 Get the refresh rate of the display mode.
int getBitsPerPixel () const noexcept
 Get the color depth of the display mode.

Detailed Description

Information about a specific display mode available to a Display.

Member Function Documentation

◆ getSize()

Extent2D grem::graphics::DisplayMode::getSize ( ) const
inlinenodiscardnoexcept

Get the size of the display mode.

Returns
the size of the display mode, in screen coordinates (typically pixels).

◆ getPixelDensity()

float grem::graphics::DisplayMode::getPixelDensity ( ) const
inlinenodiscardnoexcept

Get the pixel density of the display mode.

Returns
the pixel density scale of the display mode. For example, a 1920x1080 mode with a pixel density of 2 would have 3840x2160 pixels.

◆ getRefreshRate()

float grem::graphics::DisplayMode::getRefreshRate ( ) const
inlinenodiscardnoexcept

Get the refresh rate of the display mode.

Returns
the refresh rate of the display mode, in Hertz, or 0 if unspecified.

◆ getBitsPerPixel()

int grem::graphics::DisplayMode::getBitsPerPixel ( ) const
nodiscardnoexcept

Get the color depth of the display mode.

Returns
the number of bits of color information per pixel in the display mode's pixel format.

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