Function SDL_ISPIXELFORMAT_FOURCC
pub const fn SDL_ISPIXELFORMAT_FOURCC(format: SDL_PixelFormat) -> bool
Available on crate feature
dep_sdl3
only.Expand description
A macro to determine if an SDL_PixelFormat
is a “FourCC” format.
This covers custom and other unusual formats.
Note that this macro double-evaluates its parameter, so do not use expressions with side-effects here.
§Parameters
format
: anSDL_PixelFormat
to check.
§Return value
Returns true if the format has alpha, false otherwise.
§Thread safety
It is safe to call this macro from any thread.
§Availability
This macro is available since SDL 3.2.0.