glfwGetGammaRamp function

Pointer<GLFWgammaramp> glfwGetGammaRamp(
  1. Pointer<GLFWmonitor> monitor
)

! @brief Returns the current gamma ramp for the specified monitor.

This function returns the current gamma ramp of the specified monitor.

@paramin monitor The monitor to query. @return The current gamma ramp, or NULL if an error(@ref error_handling) occurred.

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

@remark @wayland Gamma handling is a privileged protocol, this function will thus never be implemented and emits @ref GLFW_PLATFORM_ERROR while returning NULL.

@pointer_lifetime The returned structure and its arrays are allocated and freed by GLFW. You should not free them yourself. They are valid until the specified monitor is disconnected, this function is called again for that monitor or the library is terminated.

@thread_safety This function must only be called from the main thread.

@sa @ref monitor_gamma

@since Added in version 3.0.

@ingroup monitor

GLFWAPI const GLFWgammaramp* glfwGetGammaRamp(GLFWmonitor* monitor)

Implementation

Pointer<GLFWgammaramp> glfwGetGammaRamp(Pointer<GLFWmonitor> monitor) {
  final glfwGetGammaRampLookupFunction = libglfw.lookupFunction<
      Pointer<GLFWgammaramp> Function(Pointer<GLFWmonitor> monitor),
      Pointer<GLFWgammaramp> Function(
          Pointer<GLFWmonitor> monitor)>('glfwGetGammaRamp');
  return glfwGetGammaRampLookupFunction(monitor);
}