TachyonUI 1.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
tachyon::sdlgpu::SDLGPUCommandList Class Referencefinal

#include <gui_core/graphics/sdlgpu/sdlgpu_rhi.h>

Inheritance diagram for tachyon::sdlgpu::SDLGPUCommandList:

Public Member Functions

 SDLGPUCommandList (SDLGPUGraphicsContext::Impl &device, std::vector< std::byte > &staging)
 staging takes each frame's transient data.
void Begin (uint32_t stagingEntry)
 A new frame: the last one's draws gone.
void DrawPrimitives (const RHI::GpuPipeline &pipeline, const GPUDrawPushConstants &pushConstants, uint32_t primitiveCount, uint32_t firstPrimitive, PrimitiveShape shape, std::span< const std::byte > primitives) override
 Cut where a run would read more than the 16 images a draw binds, and kept for Replay.
void UploadTransientBuffers (std::span< const RHI::UploadRequest > requests, std::span< DeviceAddress > addresses) override
RHI::ResidentBufferId UploadResidentBuffers (std::span< const RHI::UploadRequest > requests, std::span< DeviceAddress > addresses) override
RHI::ResidentState ResidentBufferState (RHI::ResidentBufferId id) const override
void ReleaseResidentBuffer (RHI::ResidentBufferId id) override
 Frees the buffer once no frame in flight reads it; an unknown id does nothing.
uint32_t MostQuads () const
 The most quads one draw has: the quads' index buffer must hold them.
void Replay (SDL_GPUCommandBuffer *commands, SDL_GPURenderPass *pass) const
 Records the kept draws into the render pass.
Public Member Functions inherited from tachyon::RHI::RenderCommandList
virtual ~RenderCommandList ()=default
virtual void UploadTransientBuffers (std::span< const UploadRequest > requests, std::span< DeviceAddress > addresses)=0
 Copies a batch of transient data into storage that remains valid until this command list's frame fence signals.
virtual ResidentBufferId UploadResidentBuffers (std::span< const UploadRequest > requests, std::span< DeviceAddress > addresses)=0
 Copies a batch of data into GPU memory that stays until released, for data drawn again over many frames (a cached scope's primitives).

Constructor & Destructor Documentation

◆ SDLGPUCommandList()

tachyon::sdlgpu::SDLGPUCommandList::SDLGPUCommandList ( SDLGPUGraphicsContext::Impl & device,
std::vector< std::byte > & staging )
inline

staging takes each frame's transient data.

A window keeps one for all its frames, so the lists keep their storage.

Member Function Documentation

◆ Begin()

void tachyon::sdlgpu::SDLGPUCommandList::Begin ( uint32_t stagingEntry)
inline

A new frame: the last one's draws gone.

stagingEntry is the buffer table's entry of the buffer the staging is copied into.

◆ DrawPrimitives()

void tachyon::sdlgpu::SDLGPUCommandList::DrawPrimitives ( const RHI::GpuPipeline & pipeline,
const GPUDrawPushConstants & pushConstants,
uint32_t primitiveCount,
uint32_t firstPrimitive,
PrimitiveShape shape,
std::span< const std::byte > primitives )
overridevirtual

Cut where a run would read more than the 16 images a draw binds, and kept for Replay.

Implements tachyon::RHI::RenderCommandList.

◆ UploadTransientBuffers()

void tachyon::sdlgpu::SDLGPUCommandList::UploadTransientBuffers ( std::span< const RHI::UploadRequest > requests,
std::span< DeviceAddress > addresses )
override

◆ UploadResidentBuffers()

RHI::ResidentBufferId tachyon::sdlgpu::SDLGPUCommandList::UploadResidentBuffers ( std::span< const RHI::UploadRequest > requests,
std::span< DeviceAddress > addresses )
override

◆ ResidentBufferState()

RHI::ResidentState tachyon::sdlgpu::SDLGPUCommandList::ResidentBufferState ( RHI::ResidentBufferId id) const
overridevirtual

◆ ReleaseResidentBuffer()

void tachyon::sdlgpu::SDLGPUCommandList::ReleaseResidentBuffer ( RHI::ResidentBufferId id)
overridevirtual

Frees the buffer once no frame in flight reads it; an unknown id does nothing.

Implements tachyon::RHI::RenderCommandList.

◆ MostQuads()

uint32_t tachyon::sdlgpu::SDLGPUCommandList::MostQuads ( ) const
inline

The most quads one draw has: the quads' index buffer must hold them.

◆ Replay()

void tachyon::sdlgpu::SDLGPUCommandList::Replay ( SDL_GPUCommandBuffer * commands,
SDL_GPURenderPass * pass ) const

Records the kept draws into the render pass.


The documentation for this class was generated from the following file: