SDL_GPUBufferCreateInfo(3type)

πŸ’– SDL_GPUBufferCreateInfo πŸ’–

okay bestie, welcome to the <SDL3/SDL_gpu.h> era of your life, because this little struct is from the SDL3 DATATYPES collection and it's literally the blueprint you hand over when you want a GPU buffer to exist. it's giving "paperwork but make it slay." πŸŽ€


✨ NAME ✨

SDL_GPUBufferCreateInfo β€” a structure specifying the parameters of a buffer.

like, it's the ~vibe description~ of a buffer before the buffer is even real. manifesting. πŸ¦‹


🌸 SYNOPSIS 🌸

#include <SDL3/SDL_gpu.h>

typedef struct SDL_GPUBufferCreateInfo
{
    SDL_GPUBufferUsageFlags usage;  /**< How the buffer is intended to be used by the client. */
    Uint32 size;                    /**< The size in bytes of the buffer. */

    SDL_PropertiesID props;         /**< A properties ID for extensions. Should be 0 if no extensions are needed. */
} SDL_GPUBufferCreateInfo;

πŸ’… DESCRIPTION πŸ’…

so here's the tea β˜• β€” the usage flags can be bitwise OR'd together for combinations of usages. yes, mix and match, it's a whole aesthetic.

⚠️ BUT β€” note that certain combinations are invalid, for example VERTEX and INDEX. not every combo is a match made in heaven, some of them are a red flag 🚩 and you should not do it.

πŸ‘‘ AVAILABILITY πŸ‘‘

this struct is available since SDL 3.2.0. so if you're on anything older, it's not you, it's the version. 😭


🫢 SEE ALSO 🫢


and that's the whole page, no notes, you ate πŸ’…βœ¨

this lil doc lives under the Simple Directmedia Layer banner, riding with SDL 3.4.18 β€” mwah, sending you and your GPU buffers all the good vibes, fr fr πŸŒˆπŸ’œ

πŸ“¦ where this page comes from