Get the data from clipboard for a given mime type.
Defined in <SDL3/SDL_clipboard.h>
void * SDL_GetClipboardData(const char *mime_type, size_t *size);
const char * | mime_type | the mime type to read from the clipboard. |
size_t * | size | a pointer filled in with the length of the returned data. |
(void *) Returns the retrieved data buffer or NULL on failure; call SDL_GetError() for more information. This should be freed with SDL_free() when it is no longer needed.
The size of text data does not include the terminator, but the text is guaranteed to be null terminated.
You may only call this function from the main thread.
This function is available since SDL 3.1.3.