From 6ccfeddf26cf85db0df21ea92aa0d620159ea4c2 Mon Sep 17 00:00:00 2001 From: Mathias Agopian Date: Mon, 12 Feb 2024 16:02:20 -0800 Subject: [PATCH] fix a typo that broke the resourceallocator cache the cache size is given in MiB not bytes, so we needed to convert it to bytes. --- filament/src/ResourceAllocator.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/filament/src/ResourceAllocator.cpp b/filament/src/ResourceAllocator.cpp index eeff5011a6..b8d1e6698e 100644 --- a/filament/src/ResourceAllocator.cpp +++ b/filament/src/ResourceAllocator.cpp @@ -109,7 +109,7 @@ size_t ResourceAllocator::TextureKey::getSize() const noexcept { } ResourceAllocator::ResourceAllocator(Engine::Config const& config, DriverApi& driverApi) noexcept - : mCacheCapacity(config.resourceAllocatorCacheSizeMB), + : mCacheCapacity(config.resourceAllocatorCacheSizeMB << 20), mCacheMaxAge(config.resourceAllocatorCacheMaxAge), mBackend(driverApi) { }