HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RV_VKCommandBuffer Class Reference

#include <RV_VKCommandBuffer.h>

Classes

struct  ResourceInfo
 

Public Types

using Callback = UT_Function< void(RV_Instance *)>
 

Public Member Functions

VkCommandBuffer getVkCmdBuf ()
 
RV_VKCommandPoolgetCmdPool ()
 
void beginRecording ()
 
void endRecording ()
 
bool waitForFinish ()
 
void addWaitSemaphore (VkSemaphore sem, VkPipelineStageFlags stage)
 
void addSignalSemaphore (VkSemaphore sem, VkPipelineStageFlags stage)
 
bool isRecording () const
 
bool isExecuting ()
 
void handleCompletionCallbacks (RV_Instance *inst)
 
void handleSubmissionCallbacks (RV_Instance *inst)
 
void addCompletionCallback (const Callback &callback)
 
void addSubmissionCallback (const Callback &callback)
 
void invalidateState ()
 
void appendLog (const UT_StringHolder &log)
 
void logImageUsage (const RV_VKImage *img)
 
void logBufferUsage (const RV_VKBuffer *buf)
 
void logAccelStructUsage (const RV_VKAccelerationStructure *accel_struct)
 
void logSetUsage (const RV_ShaderVariableSet *set)
 
 ~RV_VKCommandBuffer ()
 
 RV_VKCommandBuffer (const RV_VKCommandBuffer &)=delete
 
RV_VKCommandBufferoperator= (const RV_VKCommandBuffer &)=delete
 

Static Public Member Functions

static RV_VKCommandBufferallocate (RV_Instance *inst, RV_VKCommandPool *cmd_pool)
 

Public Attributes

RV_VKPipelineStateInfo myPipeState
 

Protected Member Functions

bool validateUsedResources (RV_Instance *inst, FILE *out=nullptr) const
 
 RV_VKCommandBuffer (RV_Instance *inst, RV_VKCommandPool *cmd_pool, VkCommandBuffer cmd_buf, const VkCommandBufferAllocateInfo &info, VkFence fence)
 

Protected Attributes

VkCommandBuffer myVkCmdBuf
 
class RV_VKCommandPoolmyCmdPool
 
RV_InstancemyInst = nullptr
 
VkCommandBufferLevel myLevel = VK_COMMAND_BUFFER_LEVEL_PRIMARY
 
bool myIsRecording = false
 
VkFence myCompleteFence
 
UT_Array< VkPipelineStageFlagsmyWaitStages
 
UT_Array< VkSemaphore > myWaitSems
 
UT_Array< VkPipelineStageFlagsmySignalStages
 
UT_Array< VkSemaphore > mySignalSems
 
UT_Array< CallbackmyCompletionCallbacks
 
UT_Array< CallbackmySubmissionCallbacks
 
UT_Array< ResourceInfomyImageIDs
 
UT_Array< ResourceInfomyBufferIDs
 
UT_Array< ResourceInfomyAccelStructIDs
 
UT_Array< ResourceInfomySetIDs
 
fpreal mySubmitTime = 0.f
 
UT_Array< UT_StringHoldermyLogEntries
 

Friends

class RV_Instance
 
class RV_VKCommandPool
 
class RV_VKQueue
 

Detailed Description

Definition at line 37 of file RV_VKCommandBuffer.h.

Member Typedef Documentation

Constructor & Destructor Documentation

RV_VKCommandBuffer::~RV_VKCommandBuffer ( )
RV_VKCommandBuffer::RV_VKCommandBuffer ( const RV_VKCommandBuffer )
delete
RV_VKCommandBuffer::RV_VKCommandBuffer ( RV_Instance inst,
RV_VKCommandPool cmd_pool,
VkCommandBuffer  cmd_buf,
const VkCommandBufferAllocateInfo info,
VkFence  fence 
)
inlineprotected

Definition at line 189 of file RV_VKCommandBuffer.h.

Member Function Documentation

void RV_VKCommandBuffer::addCompletionCallback ( const Callback callback)
inline

Definition at line 100 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::addSignalSemaphore ( VkSemaphore  sem,
VkPipelineStageFlags  stage 
)
void RV_VKCommandBuffer::addSubmissionCallback ( const Callback callback)
inline

Definition at line 105 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::addWaitSemaphore ( VkSemaphore  sem,
VkPipelineStageFlags  stage 
)
static RV_VKCommandBuffer* RV_VKCommandBuffer::allocate ( RV_Instance inst,
RV_VKCommandPool cmd_pool 
)
static
void RV_VKCommandBuffer::appendLog ( const UT_StringHolder log)
inline

Definition at line 121 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::beginRecording ( )
void RV_VKCommandBuffer::endRecording ( )
RV_VKCommandPool* RV_VKCommandBuffer::getCmdPool ( )
inline

Definition at line 50 of file RV_VKCommandBuffer.h.

VkCommandBuffer RV_VKCommandBuffer::getVkCmdBuf ( )
inline

Definition at line 44 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::handleCompletionCallbacks ( RV_Instance inst)
inline

Definition at line 70 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::handleSubmissionCallbacks ( RV_Instance inst)
inline

Definition at line 88 of file RV_VKCommandBuffer.h.

void RV_VKCommandBuffer::invalidateState ( )
inline

Definition at line 112 of file RV_VKCommandBuffer.h.

bool RV_VKCommandBuffer::isExecuting ( )
bool RV_VKCommandBuffer::isRecording ( ) const
void RV_VKCommandBuffer::logAccelStructUsage ( const RV_VKAccelerationStructure accel_struct)
void RV_VKCommandBuffer::logBufferUsage ( const RV_VKBuffer buf)
void RV_VKCommandBuffer::logImageUsage ( const RV_VKImage img)
void RV_VKCommandBuffer::logSetUsage ( const RV_ShaderVariableSet set)
RV_VKCommandBuffer& RV_VKCommandBuffer::operator= ( const RV_VKCommandBuffer )
delete
bool RV_VKCommandBuffer::validateUsedResources ( RV_Instance inst,
FILE *  out = nullptr 
) const
protected
bool RV_VKCommandBuffer::waitForFinish ( )

Friends And Related Function Documentation

friend class RV_Instance
friend

Definition at line 203 of file RV_VKCommandBuffer.h.

friend class RV_VKCommandPool
friend

Definition at line 204 of file RV_VKCommandBuffer.h.

friend class RV_VKQueue
friend

Definition at line 205 of file RV_VKCommandBuffer.h.

Member Data Documentation

UT_Array<ResourceInfo> RV_VKCommandBuffer::myAccelStructIDs
protected

Definition at line 184 of file RV_VKCommandBuffer.h.

UT_Array<ResourceInfo> RV_VKCommandBuffer::myBufferIDs
protected

Definition at line 183 of file RV_VKCommandBuffer.h.

class RV_VKCommandPool* RV_VKCommandBuffer::myCmdPool
protected

Definition at line 148 of file RV_VKCommandBuffer.h.

VkFence RV_VKCommandBuffer::myCompleteFence
protected

Definition at line 158 of file RV_VKCommandBuffer.h.

UT_Array<Callback> RV_VKCommandBuffer::myCompletionCallbacks
protected

Definition at line 167 of file RV_VKCommandBuffer.h.

UT_Array<ResourceInfo> RV_VKCommandBuffer::myImageIDs
protected

Definition at line 182 of file RV_VKCommandBuffer.h.

RV_Instance* RV_VKCommandBuffer::myInst = nullptr
protected

Definition at line 149 of file RV_VKCommandBuffer.h.

bool RV_VKCommandBuffer::myIsRecording = false
protected

Definition at line 155 of file RV_VKCommandBuffer.h.

VkCommandBufferLevel RV_VKCommandBuffer::myLevel = VK_COMMAND_BUFFER_LEVEL_PRIMARY
protected

Definition at line 152 of file RV_VKCommandBuffer.h.

UT_Array<UT_StringHolder> RV_VKCommandBuffer::myLogEntries
protected

Definition at line 187 of file RV_VKCommandBuffer.h.

RV_VKPipelineStateInfo RV_VKCommandBuffer::myPipeState

Definition at line 140 of file RV_VKCommandBuffer.h.

UT_Array<ResourceInfo> RV_VKCommandBuffer::mySetIDs
protected

Definition at line 185 of file RV_VKCommandBuffer.h.

UT_Array<VkSemaphore> RV_VKCommandBuffer::mySignalSems
protected

Definition at line 164 of file RV_VKCommandBuffer.h.

UT_Array<VkPipelineStageFlags> RV_VKCommandBuffer::mySignalStages
protected

Definition at line 163 of file RV_VKCommandBuffer.h.

UT_Array<Callback> RV_VKCommandBuffer::mySubmissionCallbacks
protected

Definition at line 168 of file RV_VKCommandBuffer.h.

fpreal RV_VKCommandBuffer::mySubmitTime = 0.f
protected

Definition at line 186 of file RV_VKCommandBuffer.h.

VkCommandBuffer RV_VKCommandBuffer::myVkCmdBuf
protected

Definition at line 147 of file RV_VKCommandBuffer.h.

UT_Array<VkSemaphore> RV_VKCommandBuffer::myWaitSems
protected

Definition at line 161 of file RV_VKCommandBuffer.h.

UT_Array<VkPipelineStageFlags> RV_VKCommandBuffer::myWaitStages
protected

Definition at line 160 of file RV_VKCommandBuffer.h.


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