SDL_BINDGPUVERTEXSTORAGETEXTURES(3)
π SDL_BindGPUVertexStorageTextures π
okay so bestie, welcome to the SDL3 FUNCTIONS corner of the manual, and today's main character is SDL_BindGPUVertexStorageTextures β¨
πΈ NAME πΈ
SDL_BindGPUVertexStorageTextures β binds storage textures so your vertex shader can actually use them π
π¦ SYNOPSIS π¦
#include <SDL3/SDL_gpu.h>
void SDL_BindGPUVertexStorageTextures(
SDL_GPURenderPass *render_pass,
Uint32 first_slot,
SDL_GPUTexture *const *storage_textures,
Uint32 num_bindings);
π DESCRIPTION π
okay so first things first, queen: these textures must have been created with SDL_GPU_TEXTUREUSAGE_GRAPHICS_STORAGE_READ. no exceptions, that's the vibe check they have to pass π«Ά
and the textures you're binding have to have a matching type declared in the shader β like 2D, 3D, 2DMS, etc. mismatched types? not slay. the shader said what it said π
also, be sure your shader is set up according to the requirements documented in SDL_CreateGPUShader(). literally go read that one too, it's giving prerequisites π
β¨ FUNCTION PARAMETERS β¨
render_passβ a render pass handle π¨first_slotβ the vertex storage texture slot to begin binding from π―storage_texturesβ an array of storage textures π§num_bindingsβ the number of storage texture to bind from the array π’
π AVAILABILITY π
this function is available since SDL 3.2.0 π
π SEE ALSO π
ngl, if you skipped the SDL_CreateGPUShader() requirement you're gonna have a bad time. it's not me being dramatic, it's just fr fr the rules π
Simple Directmedia Layer β SDL 3.4.18 β mwah, that's a wrap bestie, go bind some textures and slay π β¨π¦πΈ
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms