glfwSetCursor

Sets the cursor for the window.

This function sets the cursor image to be used when the cursor is over the content area of the specified window. The set cursor will only be visible when the cursor mode of the window is GLFW_CURSOR_NORMAL.

On some platforms, the set cursor may not be visible unless the window also has input focus.

extern (C) @nogc nothrow __gshared
void
glfwSetCursor

Parameters

window GLFWwindow*

The window to set the cursor for.

cursor GLFWcursor*

The cursor to set, or null to switch back to the default arrow cursor.

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

Thread Safety

This function must only be called from the main thread.

@sa @ref cursor_object

Meta

Since

Added in version 3.1.

Ingroup: input