Sync SDL3 wiki -> header

This commit is contained in:
SDL Wiki Bot 2024-10-04 19:29:06 +00:00
parent e8c852d77c
commit a7e4e9219a

View file

@ -30,9 +30,9 @@
* *
* A basic workflow might be something like this: * A basic workflow might be something like this:
* *
* The app creates a GPU device with SDL_GPUCreateDevice(), and assigns it to a * The app creates a GPU device with SDL_GPUCreateDevice(), and assigns it to
* window with SDL_ClaimWindowForGPUDevice()--although strictly speaking you can * a window with SDL_ClaimWindowForGPUDevice()--although strictly speaking you
* render offscreen entirely, perhaps for image processing, and not use a * can render offscreen entirely, perhaps for image processing, and not use a
* window at all. * window at all.
* *
* Next the app prepares static data (things that are created once and used * Next the app prepares static data (things that are created once and used
@ -47,11 +47,11 @@
* SDL_CreateGPUGraphicsPipeline() * SDL_CreateGPUGraphicsPipeline()
* *
* To render, the app creates one or more command buffers, with * To render, the app creates one or more command buffers, with
* SDL_AcquireGPUCommandBuffer(). Command buffers collect rendering instructions * SDL_AcquireGPUCommandBuffer(). Command buffers collect rendering
* that will be submitted to the GPU in batch. Complex scenes can use multiple * instructions that will be submitted to the GPU in batch. Complex scenes can
* command buffers, maybe configured across multiple threads in parallel, as * use multiple command buffers, maybe configured across multiple threads in
* long as they are submitted in the correct order, but many apps will just * parallel, as long as they are submitted in the correct order, but many apps
* need one command buffer per frame. * will just need one command buffer per frame.
* *
* Rendering can happen to a texture (what other APIs call a "render target") * Rendering can happen to a texture (what other APIs call a "render target")
* or it can happen to the swapchain texture (which is just a special texture * or it can happen to the swapchain texture (which is just a special texture
@ -66,8 +66,8 @@
* simultaneously. If the set of textures being rendered to needs to change, * simultaneously. If the set of textures being rendered to needs to change,
* the Render Pass must be ended and a new one must be begun. * the Render Pass must be ended and a new one must be begun.
* *
* The app calls SDL_BeginGPURenderPass(). Then it sets states it needs for each * The app calls SDL_BeginGPURenderPass(). Then it sets states it needs for
* draw: * each draw:
* *
* - SDL_BindGPUGraphicsPipeline() * - SDL_BindGPUGraphicsPipeline()
* - SDL_SetGPUViewport() * - SDL_SetGPUViewport()