sdlGpuTextureFormatTexelBlockSize function

int sdlGpuTextureFormatTexelBlockSize(
  1. int format
)

Obtains the texel block size for a texture format.

\param format the texture format you want to know the texel size of. \returns the texel block size of the texture format.

\since This function is available since SDL 3.1.3.

\sa SDL_UploadToGPUTexture

extern SDL_DECLSPEC Uint32 SDLCALL SDL_GPUTextureFormatTexelBlockSize( SDL_GPUTextureFormat format)

Implementation

int sdlGpuTextureFormatTexelBlockSize(int format) {
  final sdlGpuTextureFormatTexelBlockSizeLookupFunction = libSdl3
      .lookupFunction<Uint32 Function(Int32 format), int Function(int format)>(
          'SDL_GPUTextureFormatTexelBlockSize');
  return sdlGpuTextureFormatTexelBlockSizeLookupFunction(format);
}