SDL 3.0
SDL_GPUTextureCreateInfo Struct Reference

#include <SDL_gpu.h>

Data Fields

SDL_GPUTextureType type
 
SDL_GPUTextureFormat format
 
SDL_GPUTextureUsageFlags usage
 
Uint32 width
 
Uint32 height
 
Uint32 layer_count_or_depth
 
Uint32 num_levels
 
SDL_GPUSampleCount sample_count
 
SDL_PropertiesID props
 

Detailed Description

A structure specifying the parameters of a texture.

Usage flags can be bitwise OR'd together for combinations of usages. Note that certain usage combinations are invalid, for example SAMPLER and GRAPHICS_STORAGE.

Since
This struct is available since SDL 3.0.0
See also
SDL_CreateGPUTexture

Definition at line 1298 of file SDL_gpu.h.

Field Documentation

◆ format

SDL_GPUTextureFormat SDL_GPUTextureCreateInfo::format

The pixel format of the texture.

Definition at line 1301 of file SDL_gpu.h.

◆ height

Uint32 SDL_GPUTextureCreateInfo::height

The height of the texture.

Definition at line 1304 of file SDL_gpu.h.

◆ layer_count_or_depth

Uint32 SDL_GPUTextureCreateInfo::layer_count_or_depth

The layer count or depth of the texture. This value is treated as a layer count on 2D array textures, and as a depth value on 3D textures.

Definition at line 1305 of file SDL_gpu.h.

◆ num_levels

Uint32 SDL_GPUTextureCreateInfo::num_levels

The number of mip levels in the texture.

Definition at line 1306 of file SDL_gpu.h.

◆ props

SDL_PropertiesID SDL_GPUTextureCreateInfo::props

A properties ID for extensions. Should be 0 if no extensions are needed.

Definition at line 1309 of file SDL_gpu.h.

◆ sample_count

SDL_GPUSampleCount SDL_GPUTextureCreateInfo::sample_count

The number of samples per texel. Only applies if the texture is used as a render target.

Definition at line 1307 of file SDL_gpu.h.

◆ type

SDL_GPUTextureType SDL_GPUTextureCreateInfo::type

The base dimensionality of the texture.

Definition at line 1300 of file SDL_gpu.h.

◆ usage

SDL_GPUTextureUsageFlags SDL_GPUTextureCreateInfo::usage

How the texture is intended to be used by the client.

Definition at line 1302 of file SDL_gpu.h.

◆ width

Uint32 SDL_GPUTextureCreateInfo::width

The width of the texture.

Definition at line 1303 of file SDL_gpu.h.


The documentation for this struct was generated from the following file: