SDL_SurfaceHasColorKey - Man Page

Returns whether the surface has a color key.

Header File

Defined in SDL3/SDL_surface.h

Synopsis

#include "SDL3/SDL.h"

bool SDL_SurfaceHasColorKey(SDL_Surface *surface);

Description

It is safe to pass a NULL surface here; it will return false.

Function Parameters

surface

the SDL_Surface
structure to query.

Return Value

Returns true if the surface has a color key, false otherwise.

Availability

This function is available since SDL 3.2.0.

See Also

·(3), SDL_SetSurfaceColorKey(3), ·(3), SDL_GetSurfaceColorKey(3)

Referenced By

SDL_GetSurfaceColorKey(3), SDL_SetSurfaceColorKey(3).

SDL 3.2.2 Simple Directmedia Layer SDL3 FUNCTIONS