SDL_GetCursor(3)
β¨ SDL_GetCursor β¨
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, page SDL_GetCursor(3), and it's giving main character energy for your mouse pointer π
πΈ NAME πΈ
SDL_GetCursor β Get the active cursor.
π SYNOPSIS π
#include <SDL3/SDL_mouse.h>
SDL_Cursor * SDL_GetCursor(void);
π¦ DESCRIPTION π¦
So basically this function hands you back a pointer to the current cursor, and the tea is: that cursor is owned by the library. That means it's not necessary to free it with SDL_DestroyCursor(). Do not be out here freeing other people's cursors, bestie, that's not your cursor to free π
π RETURN VALUE π
It returns the active cursor, or NULL if there is no mouse. No mouse = no cursor, periodt.
π§ THREAD SAFETY π§
This function should only be called on the main thread. Like, main character thread only. Don't be side-thread-ing this one, fr fr π
β AVAILABILITY β
This function is available since SDL 3.2.0. iconic.
π SEE ALSO π
Simple Directmedia Layer π«Ά SDL 3.4.18 π¦ and yeah, this whole vibe is SDL_GetCursor(3) β slay, go get that cursor, bestie π
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms