SDL_DuplicateSurface

Creates a new surface identical to the existing surface.

If the original surface has alternate images, the new surface will have a reference to them as well.

The returned surface should be freed with SDL_DestroySurface().

extern (C) nothrow @nogc extern
SDL_DuplicateSurface

Parameters

surface SDL_Surface*

the surface to duplicate.

Return Value

a copy of the surface or NULL on failure; call SDL_GetError() for more information.

See Also

Meta