RavEngine
Loading...
Searching...
No Matches
RGL::CommandBufferVk Struct Reference
Inheritance diagram for RGL::CommandBufferVk:
[legend]
Collaboration diagram for RGL::CommandBufferVk:
[legend]

Classes

struct  BufferLastUse
 
struct  CmdBeginCompute
 
struct  CmdBeginDebugMarker
 
struct  CmdBeginRendering
 
struct  CmdBindBuffer
 
struct  CmdBindlessSetBuffer
 
struct  CmdBindlessSetTexture
 
struct  CmdBindRenderPipeline
 
struct  CmdCopyBufferToBuffer
 
struct  CmdCopyBuffertoTexture
 
struct  CmdCopyTextureToBuffer
 
struct  CmdCopyTextureToTexture
 
struct  CmdDispatch
 
struct  CmdDispatchIndirect
 
struct  CmdDraw
 
struct  CmdDrawIndexed
 
struct  CmdEndCompute
 
struct  CmdEndDebugMarker
 
struct  CmdExecuteIndirect
 
struct  CmdExecuteIndirectIndexed
 
struct  CmdSetIndexBuffer
 
struct  CmdSetPushConstantData
 
struct  CmdSetSampler
 
struct  CmdSetScissor
 
struct  CmdSetTexture
 
struct  CmdSetVertexBuffer
 
struct  CmdSetViewport
 
struct  TextureLastUse
 

Public Member Functions

bool keyIsAllMips (const TextureLastUseKey &key)
 
void EncodeCommand (auto &&commandValue)
 
 CommandBufferVk (decltype(owningQueue) owningQueue)
 
void Reset () final
 
void Begin () final
 
void End () final
 
void BindRenderPipeline (RGLRenderPipelinePtr) final
 
void BeginRendering (RGLRenderPassPtr) final
 
void EndRendering () final
 
void BeginCompute (RGLComputePipelinePtr) final
 
void EndCompute () final
 
void DispatchCompute (uint32_t threadsX, uint32_t threadsY, uint32_t threadsZ, uint32_t threadsPerThreadgroupX=1, uint32_t threadsPerThreadgroupY=1, uint32_t threadsPerThreadgroupZ=1) final
 
void BindBuffer (RGLBufferPtr buffer, uint32_t bindingOffset, uint32_t offsetIntoBuffer=0) final
 
void BindComputeBuffer (RGLBufferPtr buffer, uint32_t binding, uint32_t offsetIntoBuffer=0) final
 
void SetVertexBuffer (RGLBufferPtr buffer, const VertexBufferBinding &bindingInfo={}) final
 
void setPushConstantData (const RGL::untyped_span &data, const uint32_t &offset)
 
void SetVertexBytes (const untyped_span data, uint32_t offset) final
 
void SetFragmentBytes (const untyped_span data, uint32_t offset) final
 
void SetComputeBytes (const untyped_span data, uint32_t offset) final
 
void SetIndexBuffer (RGLBufferPtr buffer) final
 
void SetVertexSampler (RGLSamplerPtr sampler, uint32_t index) final
 
void SetFragmentSampler (RGLSamplerPtr sampler, uint32_t index) final
 
void SetComputeSampler (RGLSamplerPtr sampler, uint32_t index) final
 
void BindBindlessBufferDescriptorSet (uint32_t set_idx) final
 
void SetVertexTexture (const TextureView &texture, uint32_t index) final
 
void SetFragmentTexture (const TextureView &texture, uint32_t index) final
 
void SetComputeTexture (const TextureView &texture, uint32_t index) final
 
void Draw (uint32_t nVertices, const DrawInstancedConfig &={}) final
 
void DrawIndexed (uint32_t nIndices, const DrawIndexedInstancedConfig &={}) final
 
void CopyTextureToBuffer (TextureView &sourceTexture, const Rect &sourceRect, size_t offset, RGLBufferPtr destBuffer) final
 
void CopyBufferToTexture (RGLBufferPtr source, uint32_t size, const TextureDestConfig &dest) final
 
void CopyBufferToBuffer (BufferCopyConfig from, BufferCopyConfig to, uint32_t size) final
 
void CopyTextureToTexture (const TextureCopyConfig &from, const TextureCopyConfig &to) final
 
void SetViewport (const Viewport &) final
 
void SetScissor (const Rect &) final
 
void UseResource (const TextureView &tx) final
 
void UseResource (const RGLBufferPtr buffer) final
 
void Commit (const CommitConfig &) final
 
void ExecuteIndirectIndexed (const IndirectConfig &) final
 
void ExecuteIndirect (const IndirectConfig &) final
 
void DispatchIndirect (const DispatchIndirectConfig &) final
 
void BeginRenderDebugMarker (const std::string &label) final
 
void BeginComputeDebugMarker (const std::string &label) final
 
void EndRenderDebugMarker () final
 
void EndComputeDebugMarker () final
 
void BlockUntilCompleted () final
 

Public Attributes

bool isInsideRenderingBlock = false
 
VkCommandBuffer commandBuffer = VK_NULL_HANDLE
 
std::shared_ptr< RenderPassVk > currentRenderPass = nullptr
 
const std::shared_ptr< CommandQueueVk > owningQueue
 
std::shared_ptr< RenderPipelineVk > currentRenderPipeline = nullptr
 
std::shared_ptr< struct ComputePipelineVk > currentComputePipeline = nullptr
 
std::unordered_set< struct SwapchainVK * > swapchainsToSignal
 
std::unordered_set< const struct TextureVk * > swapchainImages
 
std::unordered_map< TextureLastUseKey, TextureLastUse > activeTextures
 
std::unordered_map< const struct BufferVk *, BufferLastUse > activeBuffers
 
std::vector< std::variant< CmdSetVertexBuffer, CmdBeginRendering, CmdSetIndexBuffer, CmdSetSampler, CmdSetTexture, CmdDraw, CmdDrawIndexed, CmdBindBuffer, CmdExecuteIndirect, CmdExecuteIndirectIndexed, CmdDispatchIndirect, CmdSetPushConstantData, CmdBindRenderPipeline, CmdBeginDebugMarker, CmdEndDebugMarker, CmdBeginCompute, CmdEndCompute, CmdDispatch, CmdCopyTextureToBuffer, CmdCopyTextureToTexture, CmdSetViewport, CmdSetScissor, CmdCopyBufferToBuffer, CmdCopyBuffertoTexture, CmdBindlessSetTexture, CmdBindlessSetBuffer > > renderCommands
 

Member Function Documentation

◆ Begin()

void RGL::CommandBufferVk::Begin ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ BeginCompute()

void RGL::CommandBufferVk::BeginCompute ( RGLComputePipelinePtr  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ BeginComputeDebugMarker()

void RGL::CommandBufferVk::BeginComputeDebugMarker ( const std::string &  label)
finalvirtual

Implements RGL::ICommandBuffer.

◆ BeginRenderDebugMarker()

void RGL::CommandBufferVk::BeginRenderDebugMarker ( const std::string &  label)
finalvirtual

Implements RGL::ICommandBuffer.

◆ BeginRendering()

void RGL::CommandBufferVk::BeginRendering ( RGLRenderPassPtr  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ BindBindlessBufferDescriptorSet()

void RGL::CommandBufferVk::BindBindlessBufferDescriptorSet ( uint32_t  set_idx)
finalvirtual

Implements RGL::ICommandBuffer.

◆ BindBuffer()

void RGL::CommandBufferVk::BindBuffer ( RGLBufferPtr  buffer,
uint32_t  bindingOffset,
uint32_t  offsetIntoBuffer = 0 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ BindComputeBuffer()

void RGL::CommandBufferVk::BindComputeBuffer ( RGLBufferPtr  buffer,
uint32_t  binding,
uint32_t  offsetIntoBuffer = 0 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ BindRenderPipeline()

void RGL::CommandBufferVk::BindRenderPipeline ( RGLRenderPipelinePtr  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ BlockUntilCompleted()

void RGL::CommandBufferVk::BlockUntilCompleted ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ Commit()

void RGL::CommandBufferVk::Commit ( const CommitConfig &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ CopyBufferToBuffer()

void RGL::CommandBufferVk::CopyBufferToBuffer ( BufferCopyConfig  from,
BufferCopyConfig  to,
uint32_t  size 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ CopyBufferToTexture()

void RGL::CommandBufferVk::CopyBufferToTexture ( RGLBufferPtr  source,
uint32_t  size,
const TextureDestConfig &  dest 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ CopyTextureToBuffer()

void RGL::CommandBufferVk::CopyTextureToBuffer ( TextureView &  sourceTexture,
const Rect &  sourceRect,
size_t  offset,
RGLBufferPtr  destBuffer 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ CopyTextureToTexture()

void RGL::CommandBufferVk::CopyTextureToTexture ( const TextureCopyConfig &  from,
const TextureCopyConfig &  to 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ DispatchCompute()

void RGL::CommandBufferVk::DispatchCompute ( uint32_t  threadsX,
uint32_t  threadsY,
uint32_t  threadsZ,
uint32_t  threadsPerThreadgroupX = 1,
uint32_t  threadsPerThreadgroupY = 1,
uint32_t  threadsPerThreadgroupZ = 1 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ DispatchIndirect()

void RGL::CommandBufferVk::DispatchIndirect ( const DispatchIndirectConfig &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ Draw()

void RGL::CommandBufferVk::Draw ( uint32_t  nVertices,
const DrawInstancedConfig &  = {} 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ DrawIndexed()

void RGL::CommandBufferVk::DrawIndexed ( uint32_t  nIndices,
const DrawIndexedInstancedConfig &  = {} 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ End()

void RGL::CommandBufferVk::End ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ EndCompute()

void RGL::CommandBufferVk::EndCompute ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ EndComputeDebugMarker()

void RGL::CommandBufferVk::EndComputeDebugMarker ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ EndRenderDebugMarker()

void RGL::CommandBufferVk::EndRenderDebugMarker ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ EndRendering()

void RGL::CommandBufferVk::EndRendering ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ ExecuteIndirect()

void RGL::CommandBufferVk::ExecuteIndirect ( const IndirectConfig &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ ExecuteIndirectIndexed()

void RGL::CommandBufferVk::ExecuteIndirectIndexed ( const IndirectConfig &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ Reset()

void RGL::CommandBufferVk::Reset ( )
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetComputeBytes()

void RGL::CommandBufferVk::SetComputeBytes ( const untyped_span  data,
uint32_t  offset 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetComputeSampler()

void RGL::CommandBufferVk::SetComputeSampler ( RGLSamplerPtr  sampler,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetComputeTexture()

void RGL::CommandBufferVk::SetComputeTexture ( const TextureView &  texture,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetFragmentBytes()

void RGL::CommandBufferVk::SetFragmentBytes ( const untyped_span  data,
uint32_t  offset 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetFragmentSampler()

void RGL::CommandBufferVk::SetFragmentSampler ( RGLSamplerPtr  sampler,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetFragmentTexture()

void RGL::CommandBufferVk::SetFragmentTexture ( const TextureView &  texture,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetIndexBuffer()

void RGL::CommandBufferVk::SetIndexBuffer ( RGLBufferPtr  buffer)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetScissor()

void RGL::CommandBufferVk::SetScissor ( const Rect &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetVertexBuffer()

void RGL::CommandBufferVk::SetVertexBuffer ( RGLBufferPtr  buffer,
const VertexBufferBinding &  bindingInfo = {} 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetVertexBytes()

void RGL::CommandBufferVk::SetVertexBytes ( const untyped_span  data,
uint32_t  offset 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetVertexSampler()

void RGL::CommandBufferVk::SetVertexSampler ( RGLSamplerPtr  sampler,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetVertexTexture()

void RGL::CommandBufferVk::SetVertexTexture ( const TextureView &  texture,
uint32_t  index 
)
finalvirtual

Implements RGL::ICommandBuffer.

◆ SetViewport()

void RGL::CommandBufferVk::SetViewport ( const Viewport &  )
finalvirtual

Implements RGL::ICommandBuffer.

◆ UseResource() [1/2]

void RGL::CommandBufferVk::UseResource ( const RGLBufferPtr  buffer)
finalvirtual

Implements RGL::ICommandBuffer.

◆ UseResource() [2/2]

void RGL::CommandBufferVk::UseResource ( const TextureView &  tx)
finalvirtual

Implements RGL::ICommandBuffer.


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