28 size_t size()
const {
return clusters.size(); }
31 uint32_t
alloc(
const PackedMesh::Cluster* cluster,
size_t firstMeshlet,
size_t meshletCount, uint16_t bucketId, uint16_t commandId);
32 uint32_t
alloc(
const Bucket& bucket,
size_t firstMeshlet,
size_t meshletCount, uint16_t bucketId, uint16_t commandId);
33 void free(uint32_t
id, uint32_t numCluster);
35 bool commit(Tempest::Encoder<Tempest::CommandBuffer>& cmd, uint8_t fId);
37 auto ssbo() -> Tempest::StorageBuffer& {
return clustersGpu; }
38 auto ssbo() const -> const Tempest::StorageBuffer& {
return clustersGpu; }
47 std::vector<uint32_t> header;
48 std::vector<Cluster> patch;
52 Tempest::StorageBuffer indices;
53 Tempest::StorageBuffer data;
56 void patchClusters(Tempest::Encoder<Tempest::CommandBuffer>& cmd, uint8_t fId);
57 size_t implAlloc(
size_t count);
59 std::vector<Cluster> clusters;
60 std::vector<Range> freeList;
61 Tempest::StorageBuffer clustersGpu;
62 std::vector<uint32_t> clustersDurty;
63 std::atomic_bool clustersDurtyBit {
false};