sdlDuplicateSurface function
Creates a new surface identical to the existing surface.
The returned surface should be freed with SDL_FreeSurface().
\param surface the surface to duplicate. \returns a copy of the surface, or NULL on failure; call SDL_GetError() for more information. /
extern DECLSPEC SDL_Surface *SDLCALL SDL_DuplicateSurface(SDL_Surface * surface)
Implementation
Pointer<SdlSurface> sdlDuplicateSurface(Pointer<SdlSurface> surface) {
final sdlDuplicateSurfaceLookupFunction = libSdl2.lookupFunction<
Pointer<SdlSurface> Function(Pointer<SdlSurface> surface),
Pointer<SdlSurface> Function(
Pointer<SdlSurface> surface)>('SDL_DuplicateSurface');
return sdlDuplicateSurfaceLookupFunction(surface);
}