sdlGetWindowFromId function
Get a window from a stored ID.
The numeric ID is what SDL_WindowEvent references, and is necessary to map these events to specific SDL_Window objects.
\param id the ID of the window.
\returns the window associated with id
or NULL if it doesn't exist; call
SDL_GetError() for more information.
\threadsafety This function should only be called on the main thread.
\since This function is available since SDL 3.1.3.
\sa SDL_GetWindowID
extern SDL_DECLSPEC SDL_Window * SDLCALL SDL_GetWindowFromID(SDL_WindowID id)
Implementation
Pointer<SdlWindow> sdlGetWindowFromId(int id) {
final sdlGetWindowFromIdLookupFunction = libSdl3.lookupFunction<
Pointer<SdlWindow> Function(Uint32 id),
Pointer<SdlWindow> Function(int id)>('SDL_GetWindowFromID');
return sdlGetWindowFromIdLookupFunction(id);
}