Enable or disable mouse passthrough for a window.
Defined in <SDL3/SDL_video.h>
bool SDL_SetWindowMousePassthrough(SDL_Window *window, bool passthrough);| SDL_Window * | window | the window to set mouse passthrough for. |
| bool | passthrough | true to make the window transparent to mouse input, false to accept mouse input. |
(bool) Returns true on success or false on failure; call SDL_GetError() for more information.
This will add or remove the window's SDL_WINDOW_MOUSE_PASSTHROUGH flag.
When enabled, the window will lose mouse focus and will not get any further mouse, pen, or touch events (except release events for buttons held down at the time) and clicks in the window will go through and hit windows behind it.
This function should only be called on the main thread.
This function is available since SDL 3.6.0.