Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDL3/SDL_AcquireGPUSwapchainTexture: Added clarification regarding what NULL means #631

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion SDL3/SDL_AcquireGPUSwapchainTexture.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,11 @@ automatically be submitted for presentation when the command buffer is
submitted. The swapchain texture should only be referenced by the command
buffer used to acquire it. The swapchain texture handle can be filled in
with NULL under certain conditions. This is not necessarily an error. If
this function returns false then there is an error.
this function returns false then there is an error. However, the texture
handle being NULL does mean that the swapchain is not available currently.
Thus, this NULL pointer should not be passed back into SDL. Instead, it
should be considered as an indication to wait until the swapchain is
available.

The swapchain texture is managed by the implementation and must not be
freed by the user. You MUST NOT call this function from any thread other
Expand Down