summaryrefslogtreecommitdiffstats
path: root/wgpu/src/image/atlas/allocator.rs
diff options
context:
space:
mode:
Diffstat (limited to 'wgpu/src/image/atlas/allocator.rs')
-rw-r--r--wgpu/src/image/atlas/allocator.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/wgpu/src/image/atlas/allocator.rs b/wgpu/src/image/atlas/allocator.rs
index 204a5c26..a51ac1f5 100644
--- a/wgpu/src/image/atlas/allocator.rs
+++ b/wgpu/src/image/atlas/allocator.rs
@@ -33,6 +33,10 @@ impl Allocator {
pub fn is_empty(&self) -> bool {
self.allocations == 0
}
+
+ pub fn allocations(&self) -> usize {
+ self.allocations
+ }
}
pub struct Region {