SDL3FrameManager Class
Manages frame lifecycle including command buffers, swapchain acquisition, and presentation.
internal sealed class SDL3FrameManager : System.IDisposable
Inheritance System.Object → SDL3FrameManager
Implements System.IDisposable
| Methods | |
|---|---|
| BeginFrame() | Begin a new frame by acquiring command buffer and swapchain texture. Waits for the oldest in-flight fence first to guarantee the corresponding swapchain image and transfer buffer have been released by the GPU. |
| EndFrame() | End the current frame and submit the command buffer. The fence is stored for the next BeginFrame() call to wait on, bounding the CPU to at most Brine2D.Rendering.SDL3FrameManager.MaxInFlightFrames frames ahead of the GPU. |
| ReleaseInFlightFences() | Releases any fence handles still held in the in-flight circular buffer. Call this after SDL3.SDL.WaitForGPUIdle(System.IntPtr) at shutdown so all fences are already signaled before releasing them. |