Large title textures are made without their most detailed levels when the card is short of room (VICTORY_TEXTURE_DROP_LEVELS) #1219
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!1219
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1219"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@Steenax6 on GitHub · 2026-11-26 00:26 UTC · original
Steenax6:pr/texture-drop-levels→main· +1857 −129 · 8 files · 6 commits · openWhat
On a 12 GB card the title's textures do not all fit beside the targets and the buffer copies. In our runs some 22,000 textures picked by index waited for room in every run, and which ones were there differed from run to run: the first room came up lit in one run and dark in the next.
Placed, title-filled, block-compressed 2D textures of 1024 and more a side are now made as reserved textures (
tiles.rs, the machinery ofVICTORY_LEVELS_ON_DEMAND) and, past a line of host-copy bytes, without their one or two most detailed levels. Their views keep the title's first level and clamp the level of detail, so the sizes shaders read stay the title's. Levels come back while there is room (VICTORY_TEXTURE_PROMOTE_MB).VICTORY_TEXTURE_DROP_LEVELS=0turns it off;force1/force2leave levels out whatever the room.This is a different answer to the same shortage than spilling into system memory or the Series S profile, and it does not exclude either.
Commits
The first commit is #1218 (lists hold the textures they read); this branch is stacked on it, and it drops out of the diff once that one is merged. Then:
show_fromno longer lowers the title's level-of-detail clamp when it moves a view (the clamp counts the texture's levels, not the view's).host::retire_later): the sweep let go of hundreds of host copies in one call, 20 ms a frame of the submitting thread in the cutscene for reserved textures, 6 ms for staging state.VICTORY_STAGING_POOL_MB(1,024), a reused one zeroed only if nothing has filled it by its first check; reserved textures kept by description (VICTORY_RESERVED_REUSE); tiles mapped a heap at a time; only the levels an upload writes are staged (VICTORY_STAGE_LEFT_OUT=1: all). 210 -> 158 ms.VICTORY_TILED_VIEW_PUBLISH=0: at once), slots are remade by the sweep when no submission is in flight, and a view of a reduced texture changes in its clamp alone (VICTORY_TEXTURE_DROP_VIEWS=keep|shift: the earlier ways).Measured (in our tree, RTX 4070 Ti 12 GB, Ryzen 7 9800X3D)
=0is dark again.What I can and cannot say for this tree
4aa6e8c:cargo clippy --workspace --all-targets --lockedand the same with--all-featuresgive exactly the warningsmaingives (11 there, none new).cargo test --workspace --locked: the tests of the modules touched pass;indirect::tests::warp_budget_saturates_without_wraparound_and_preserves_draw_fieldsfails here onmainas well, and two WARP tests inwatch.rs/inplace.rsfailed once in a full run and pass when run by name (other builds were running on the machine). The tests oftiles.rscover the view shapes and the publish order on the software adapter.texture.rs: this tree'sVICTORY_STAGING_POOL=altis kept, the pool's sizes are the new ones. In our tree commit 3 also carried hooks for placed textures (#903, not ours, still open here); they are taken out, so this stands without it.🤖 Generated with Claude Code
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.