Home -> IDataArray -> SetBufferLayout

Description

The SetBufferLayout method defines the layout of the buffer, and whether it has an attached counter. Must be set before calling AllocateMemory.

Usage

void SetBufferLayout(size_t entryStrideInBytes, size_t entryCount, bool hasCounter = false, uint32_t counterResetValue = 0);

Argument list

entryStrideInBytes [size_t]
The byte stride of each structured data entry.
entryCount [size_t]
The number of entries to allocate in the array.
hasCounter [bool]
True to allocate an attached counter value for shader use, false to allocate only the data array.
counterResetValue [uint32_t]
The value assigned to the attached counter when it is reset.

See also