#include <DispatchGroup.h>
Definition at line 115 of file DispatchGroup.h.
◆ Builder()
skgpu::graphite::Builder::Builder |
( |
Recorder * |
recorder | ) |
|
|
explicit |
Definition at line 97 of file DispatchGroup.cpp.
97 : fObj(new DispatchGroup()), fRecorder(recorder) {
99}
◆ appendStep()
bool skgpu::graphite::Builder::appendStep |
( |
const ComputeStep * |
step, |
|
|
std::optional< WorkgroupSize > |
globalSize = std::nullopt |
|
) |
| |
Definition at line 101 of file DispatchGroup.cpp.
101 {
102 return this->appendStepInternal(
step,
103 globalSize ? *globalSize :
step->calculateGlobalDispatchSize());
104}
static int step(int x, SkScalar min, SkScalar max)
◆ appendStepIndirect()
bool skgpu::graphite::Builder::appendStepIndirect |
( |
const ComputeStep * |
step, |
|
|
BufferView |
indirectBuffer |
|
) |
| |
◆ assignSharedBuffer()
Definition at line 243 of file DispatchGroup.cpp.
243 {
247
250 fObj->fClearList.push_back({
buffer.fInfo.fBuffer,
buffer.fInfo.fOffset,
buffer.fSize});
251 }
252}
static const uint8_t buffer[]
DispatchResourceOptional fSharedSlots[kMaxComputeDataFlowSlots]
◆ assignSharedTexture()
void skgpu::graphite::Builder::assignSharedTexture |
( |
sk_sp< TextureProxy > |
texture, |
|
|
unsigned int |
slot |
|
) |
| |
Definition at line 254 of file DispatchGroup.cpp.
254 {
257
258 fObj->fTextures.push_back(std::move(
texture));
259 fOutputTable.
fSharedSlots[slot] = TextureIndex{fObj->fTextures.size() - 1u};
260}
◆ finalize()
std::unique_ptr< DispatchGroup > skgpu::graphite::Builder::finalize |
( |
| ) |
|
Definition at line 262 of file DispatchGroup.cpp.
262 {
263 auto obj = std::move(fObj);
264 fOutputTable.
reset();
265 return obj;
266}
◆ getSharedBufferResource()
BindBufferInfo skgpu::graphite::Builder::getSharedBufferResource |
( |
unsigned int |
slot | ) |
const |
Definition at line 275 of file DispatchGroup.cpp.
275 {
277
279 if (
const BufferView* slotValue = std::get_if<BufferView>(&fOutputTable.
fSharedSlots[slot])) {
280 info = slotValue->fInfo;
281 }
283}
static void info(const char *fmt,...) SK_PRINTF_LIKE(1
◆ getSharedTextureResource()
Definition at line 285 of file DispatchGroup.cpp.
285 {
287
288 const TextureIndex* idx = std::get_if<TextureIndex>(&fOutputTable.
fSharedSlots[slot]);
289 if (!idx) {
290 return nullptr;
291 }
292
294 return fObj->fTextures[idx->fValue];
295}
constexpr size_t SkToSizeT(S x)
◆ outputTable()
const OutputTable & skgpu::graphite::DispatchGroup::Builder::outputTable |
( |
| ) |
const |
|
inline |
The documentation for this class was generated from the following files: