SDL_GPUTextureSupportsFormat(3)

SDL_GPUTextureSupportsFormat3

Determines whether a texture format is supported for a given type and usage.

Usage

#include "SDL3/SDL.h"

bool SDL_GPUTextureSupportsFormat( SDL_GPUDevice *device, SDL_GPUTextureFormat format, SDL_GPUTextureType type, SDL_GPUTextureUsageFlags usage);

Header file

Defined in SDL3/SDL_gpu.h

Function parameters

device

a GPU context.

format

the texture format to check.

type

the type of texture (2D, 3D, Cube).

usage

a bitmask of all usage scenarios to check.

Return value

Returns whether the texture format is supported for this type and usage.

Availability

This function is available since SDL 3.2.0.

From libsdl3-doc 3.2.10+ds-1 in Debian 13 (Trixie). Parsed by carta from the page's man source.