GPU: distant buildings black: small textures packed back to back made one another's slots null #1264
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
good first issue
help wanted
input
INTEL
invalid
lighting
linux-proton
memory
needs-info
needs-logs
needs-rebase
NVIDIA
performance
pr-diagnostics
pr-docs
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
rendering
report
series-s
shaders
spam
startup
upstream
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/trustno1-coder--VIctory-NVIDIA!1264
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1264"
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?
@CristianCiubancan on GitHub · 2026-11-28 16:44 UTC · original
CristianCiubancan:fix/stale-texture-neighbours→main· +65 −1 · 1 files · 1 commits · merged 2026-11-28 19:39 UTCWhat was wrong. Buildings and towers seen from a distance have black walls; the same building is right up close. A game frame recorded at two copies of one building, the near one beige and the far one black, shows the far walls' draws (
MS_VS_TransformDwithPS_DeferredTextured) writing an albedo of zero although their textures and vertex streams all hold data.The far mesh program takes the walls' tint from a colour table: a 1D texture picked from the heap by an index in the material record, read with
image_load. In the recorded frame that slot holds a null view.Why.
Spans::noteunderRule::Startmakes an older placed view stale when a newer one starts withinHEAD(4 KiB) of it, on the ground that no two textures share the block of their smallest levels. The title's colour tables are 256 bytes each and lie back to back, so every table written makes its neighbours null. A run with each such event written down (RTX 5070 Ti, Series X profile, a few minutes of play):The far building's table, from that log: slot 76523,
[0xc042be000, 0xc042be100), made stale by a view at0xc042bea00and again by the next table at0xc042be100.The change.
heads_meet). Larger textures are judged as before.Tested.
small_neighbours_stay(the logged addresses) andviews_of_no_memory_take_no_place. Both fail onmainand pass here.packed_neighbours_stayandspans_say_the_next_start_and_the_lowest_level_viewedpass unchanged.cargo test -p victory-gpu --lib: 456 passed, 0 failed, 36 ignored.VICTORY_STALE_TEXTURES=0onmainplus #996 the walls are right, which pointed at the rule; with this change and the rule at its default they are right too. Checked by eye by the user who reported it, on a build that also had #996 and #1197.Not measured. Memory and frame rate. Slots that used to be made null now keep their textures, so the texture queue holds somewhat more; I have no figure for it.
🤖 Generated with Claude Code
@Marsietiss on GitHub · 2026-11-28 19:18 UTC · original
Heads-up from testing (RTX 5080, Series S mode): in our merged build (our tree + #1264 + Vice-Tay #424 + #1298 + #1322 + a RAM-trim change) we saw wrong textures in game: a pedestrian's face painted rainbow-coloured and a glass door filled with blocky gold tiles. The same happened in the build without the RAM-trim change. #1264 is our main suspect, since it touches descriptor slots / address-0 views, but we have NOT bisected it yet, so this may well be one of the other changes or an interaction. I will report back if I can pin it down by removing #1264 alone.