Skip to content

cf_texture_update_layer

Category: graphics
GitHub: cute_graphics.h


Uploads pixels to one face, layer, or slice of a non-2D texture.

void cf_texture_update_layer(CF_Texture texture, void* data, int size, int layer);
Parameters Description
texture The texture, made with a CF_TextureType other than 2D.
data The pixel data for one full face/layer/slice.
size The size of data in bytes.
layer Cube face index 0-5 (+X, -X, +Y, -Y, +Z, -Z), array layer, or 3D z-slice.

Remarks

cf_texture_update uploads the whole image of a 2D texture; this is its per-layer counterpart for cube maps, texture arrays, and 3D textures (mip level 0). For a specific mip of a layer use cf_texture_update_layer_mip.

CF_Texture
CF_TextureType
cf_texture_update
cf_texture_update_mip
cf_texture_update_layer_mip
cf_make_texture