mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-24 00:00:13 +00:00
Increase texture cache budgets to 4GB and cap repetitive warnings
Raise all texture cache defaults from 1GB to 4GB to reduce rejections. Cap cache-full warnings (texture + model) to 3 messages per renderer, and cap update block parse errors to 5 messages.
This commit is contained in:
parent
820a36ac12
commit
9e1a913060
6 changed files with 19 additions and 12 deletions
|
|
@ -197,7 +197,7 @@ bool TerrainRenderer::initialize(VkContext* ctx, VkDescriptorSetLayout perFrameL
|
|||
opaqueAlphaTexture->createSampler(device, VK_FILTER_LINEAR, VK_FILTER_LINEAR,
|
||||
VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE);
|
||||
textureCacheBudgetBytes_ =
|
||||
envSizeMBOrDefault("WOWEE_TERRAIN_TEX_CACHE_MB", 512) * 1024ull * 1024ull;
|
||||
envSizeMBOrDefault("WOWEE_TERRAIN_TEX_CACHE_MB", 4096) * 1024ull * 1024ull;
|
||||
LOG_INFO("Terrain texture cache budget: ", textureCacheBudgetBytes_ / (1024 * 1024), " MB");
|
||||
|
||||
LOG_INFO("Terrain renderer initialized (Vulkan)");
|
||||
|
|
@ -461,7 +461,7 @@ VkTexture* TerrainRenderer::loadTexture(const std::string& path) {
|
|||
size_t base = static_cast<size_t>(blp.width) * static_cast<size_t>(blp.height) * 4ull;
|
||||
size_t approxBytes = base + (base / 3);
|
||||
if (textureCacheBytes_ + approxBytes > textureCacheBudgetBytes_) {
|
||||
if (textureBudgetRejectWarnings_ < 8 || (textureBudgetRejectWarnings_ % 120) == 0) {
|
||||
if (textureBudgetRejectWarnings_ < 3) {
|
||||
LOG_WARNING("Terrain texture cache full (", textureCacheBytes_ / (1024 * 1024),
|
||||
" MB / ", textureCacheBudgetBytes_ / (1024 * 1024),
|
||||
" MB), rejecting texture: ", path);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue