You can create a mousetrap from an SDL surface through the mousetrap_create or mousetrap_create_with_id API functions by specifying MT_SDL as the source_type parameter.
The source_flags parameter should be either 0 or MT_SDL_IGNORE_COLORKEY.
If source_flags is 0, the SDL surface is processed and any transparent pixels in the surface end up as transparent in the resulting mousetrap.
If source_flags is set to MT_SDL_IGNORE_COLORKEY, a mousetrap is created with the dimensions of the SDL surface sent in the source parameter.
The MT_SDL_IGNORE_COLORKEY flag is defined in <mousetrap/libsdl_surface_support.h>
The source parameter is the SDL surface you wish to make a mousetrap out of. The resulting mousetrap is created with the dimensions of the SDL surface.