Changing vertex data interfaces

This commit is contained in:
Dynamitos
2024-06-25 08:59:09 +02:00
parent bd63b14260
commit c352555b0b
11 changed files with 131 additions and 158 deletions
+4 -3
View File
@@ -15,6 +15,7 @@ DECLARE_REF(MaterialInstance)
DECLARE_REF(Mesh)
struct MeshId {
uint64 id;
operator uint64() const { return id; }
std::strong_ordering operator<=>(const MeshId& other) const { return id <=> other.id; }
bool operator==(const MeshId& other) const { return id == other.id; }
};
@@ -102,9 +103,9 @@ class VertexData {
Array<TransparentDraw> transparentData;
std::mutex vertexDataLock;
Map<MeshId, MeshData> meshData;
Map<MeshId, uint64> meshOffsets;
Map<MeshId, uint64> meshVertexCounts;
Array<MeshData> meshData;
Array<uint64> meshOffsets;
Array<uint64> meshVertexCounts;
Array<MeshletDescription> meshlets;
Array<uint8> primitiveIndices;