Struct VideoMode
This structure represents a display video mode.
Inherited Members
Namespace: OpenTK.Platform
Assembly: OpenTK.Platform.dll
Syntax
public struct VideoMode
Constructors
VideoMode(int, int, float, int)
Initializes a new instance of the VideoMode struct.
Declaration
public VideoMode(int width, int height, float refreshRate, int bitsPerPixel)
Parameters
Type | Name | Description |
---|---|---|
int | width | The width of the video mode. |
int | height | The height of the video mode. |
float | refreshRate | The refresh rate of the video mode. |
int | bitsPerPixel | The color depth of the video mode. |
Fields
BitsPerPixel
Number of bits used to represent each color in the video mode.
Declaration
public int BitsPerPixel
Field Value
Type | Description |
---|---|
int |
Height
Height in pixels of the video mode.
Declaration
public int Height
Field Value
Type | Description |
---|---|
int |
RefreshRate
Refresh rate in Hz of the video mode.
Declaration
public float RefreshRate
Field Value
Type | Description |
---|---|
float |
Width
Width in pixels of the video mode.
Declaration
public int Width
Field Value
Type | Description |
---|---|
int |
Methods
ToString()
Returns the video mode as a string with the format "{Width}x{Height}@{RefreshRate} ({RedBits}:{GreenBits}:{BlueBits})".
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string | The string representation of the video mode. |