File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -16262,6 +16262,9 @@ VMA_CALL_PRE void VMA_CALL_POST vmaBuildStatsString(
1626216262 VmaJsonWriter json(allocator->GetAllocationCallbacks(), sb);
1626316263 json.BeginObject();
1626416264
16265+ VmaBudget budget[VK_MAX_MEMORY_HEAPS];
16266+ allocator->GetBudget(budget, 0, allocator->GetMemoryHeapCount());
16267+
1626516268 VmaStats stats;
1626616269 allocator->CalculateStats(&stats);
1626716270
@@ -16286,6 +16289,20 @@ VMA_CALL_PRE void VMA_CALL_POST vmaBuildStatsString(
1628616289 }
1628716290 json.EndArray();
1628816291
16292+ json.WriteString("Budget");
16293+ json.BeginObject();
16294+ {
16295+ json.WriteString("BlockBytes");
16296+ json.WriteNumber(budget[heapIndex].blockBytes);
16297+ json.WriteString("AllocationBytes");
16298+ json.WriteNumber(budget[heapIndex].allocationBytes);
16299+ json.WriteString("Usage");
16300+ json.WriteNumber(budget[heapIndex].usage);
16301+ json.WriteString("Budget");
16302+ json.WriteNumber(budget[heapIndex].budget);
16303+ }
16304+ json.EndObject();
16305+
1628916306 if(stats.memoryHeap[heapIndex].blockCount > 0)
1629016307 {
1629116308 json.WriteString("Stats");
You can’t perform that action at this time.
0 commit comments