10 for (
int i = descriptorCount - 1; i >= 0; i--) {
44 for(
int i = newSize-1; i >= 0; i--)
Used when we allocate memory in finite space (e.g. array) and run out of space.
uint32_t allocate()
Get an index where there is no data in the array.
void reset(int newSize)
Resets all values in the buffers and allocates with new size.
size_t getCapacity() const
std::stack< uint32_t > freeIndices
std::vector< uint32_t > usedIndices
DescriptorIndexAllocator()=delete
const std::vector< uint32_t > & getUsedIndices() const
Gets the indices of all allocated fields in the array.
void free(uint32_t index)
Frees a cell in the array where the memory is not used anymore.
Log category system implementation.