#include <GrBufferAllocPool.h>
Definition at line 323 of file GrBufferAllocPool.h.
◆ GrDrawIndirectBufferAllocPool()
◆ makeIndexedSpace()
Definition at line 337 of file GrBufferAllocPool.h.
338 {
341 }
void * makeSpace(size_t size, size_t alignment, sk_sp< const GrBuffer > *buffer, size_t *offset)
static const uint8_t buffer[]
◆ makeSpace()
◆ putBack()
void GrDrawIndirectBufferAllocPool::putBack |
( |
int |
drawCount | ) |
|
|
inline |
◆ putBackIndexed()
void GrDrawIndirectBufferAllocPool::putBackIndexed |
( |
int |
drawCount | ) |
|
|
inline |
◆ reset()
void GrBufferAllocPool::reset |
( |
| ) |
|
Invalidates all the data in the pool, unrefs non-preallocated buffers.
Definition at line 70 of file GrBufferAllocPool.cpp.
113 {
115 fBytesInUse = 0;
116 this->deleteBlocks();
117 this->resetCpuData(0);
119}
◆ unmap()
void GrBufferAllocPool::unmap |
( |
| ) |
|
Ensures all buffers are unmapped and have all data written to them. Call before drawing using buffers from the pool.
Definition at line 65 of file GrBufferAllocPool.cpp.
121 {
123
124 if (fBufferPtr) {
125 BufferBlock& block = fBlocks.back();
127 if (!
buffer->isCpuBuffer()) {
130 } else {
131 size_t flushSize = block.fBuffer->size() - block.fBytesFree;
132 this->flushCpuData(fBlocks.back(), flushSize);
133 }
134 }
135 fBufferPtr = nullptr;
136 }
138}
#define UNMAP_BUFFER(block)
The documentation for this class was generated from the following file: