Scroll to navigation

SDL_SetSurfacePalette(3) SDL3 FUNCTIONS SDL_SetSurfacePalette(3)

NAME

SDL_SetSurfacePalette - Set the palette used by a surface.

SYNOPSIS

#include <SDL3/SDL_surface.h>
bool SDL_SetSurfacePalette(SDL_Surface *surface, SDL_Palette *palette);

DESCRIPTION

A single palette can be shared with many surfaces.

FUNCTION PARAMETERS

the SDL_Surface structure to update.
the SDL_Palette structure to use.

RETURN VALUE

for more information.

THREAD SAFETY

This function is not thread safe.

AVAILABILITY

This function is available since SDL 3.2.0.

SEE ALSO

SDL_CreatePalette(3), SDL_GetSurfacePalette(3)

SDL 3.2.14 Simple Directmedia Layer