glfwGetVideoMode

Returns the current mode of the specified monitor.

This function returns the current video mode of the specified monitor. If you have created a full screen window for that monitor, the return value will depend on whether that window is iconified.

extern (C) @nogc nothrow __gshared
const(GLFWvidmode)*
glfwGetVideoMode

Parameters

monitor GLFWmonitor*

The monitor to query.

Return Value

Type: const(GLFWvidmode)*

The current mode of the monitor, or null if an error occurred.

Errors: Possible errors include @ref GLFW_NOT_INITIALIZED and @ref GLFW_PLATFORM_ERROR.

Pointer lifetime

The returned array is allocated and freed by GLFW. You should not free it yourself. It is valid until the specified monitor is disconnected or the library is terminated.

Thread Safety

This function must only be called from the main thread.

@sa @ref monitor_modes @sa @ref glfwGetVideoModes

Meta

Since

Added in version 3.0. Replaces glfwGetDesktopMode.

Ingroup: monitor