#include <IndirectBufferLayout.h>
Public Member Functions | |
AZ_TYPE_INFO (IndirectBufferLayout, "{1D9A08FE-0C13-4AB4-9556-ECE97A27F42D}") | |
AZ_CLASS_ALLOCATOR (IndirectBufferLayout, SystemAllocator) | |
bool | IsFinalized () const |
bool | Finalize () |
HashValue64 | GetHash (HashValue64 seed=HashValue64{ 0 }) const |
Returns the hash computed in Finalize. | |
bool | AddIndirectCommand (const IndirectCommandDescriptor &command) |
AZStd::span< const IndirectCommandDescriptor > | GetCommands () const |
Returns the list of indirect commands of the layout. Must be called after the layout is finalized. | |
IndirectCommandIndex | FindCommandIndex (const IndirectCommandDescriptor &command) const |
IndirectBufferLayoutType | GetType () const |
Static Public Member Functions | |
static void | Reflect (AZ::ReflectContext *context) |
Describes a sequence of indirect commands of an Indirect Buffer. The order in which the commands are added to the layout is preserved and defines the offset of the command.
To use the class, add commands using AddIndirectCommand, and call Finalize to complete the construction of the layout.
bool AZ::RHI::IndirectBufferLayout::AddIndirectCommand | ( | const IndirectCommandDescriptor & | command | ) |
Adds a new indirect command to the end of the layout. This must be called before the layout is finalized.
command | The descriptor of the command to add. |
bool AZ::RHI::IndirectBufferLayout::Finalize | ( | ) |
Finalizes the layout for access. Must be called prior to usage or serialization. It is not permitted to mutate the layout once Finalize is called.
IndirectCommandIndex AZ::RHI::IndirectBufferLayout::FindCommandIndex | ( | const IndirectCommandDescriptor & | command | ) | const |
Returns the position of a command. Must be called after the layout is finalized.
command | The descriptor of the command to find. |
IndirectBufferLayoutType AZ::RHI::IndirectBufferLayout::GetType | ( | ) | const |
Returns the type of the main command of the layout. Every layout has one main command. Must be called after the layout is finalized.