Shaders: centroid position with conservative depth #565
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!565
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/565/head"
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?
@SAitken91 on GitHub · 2026-11-24 05:00 UTC · original
SAitken91:shader/conservative-depth-position→main· +7 −0 · 1 files · 1 commits · merged 2026-11-24 08:18 UTCPixel programs that write
SV_DepthLessEqualorSV_DepthGreaterEqualfailed validation (14 in shaders.rpf, for examplePS_OctaSLODReZ):Change
When a pixel program's outputs include a conservative depth (kinds 18 and 19), its
SV_Positioninput is declaredlinear_noperspective_centroid(5) instead oflinear_noperspective(4). This matches what DXC declares for the same case. Without multisampling the position's value is the same.Results
victory translate --validate shaders.rpf: vertex/pixel validated 12172 → 12186. The error is gone from the list.Testing
cargo test -p victory-shader: 69 passed. Clippy and rustfmt are clean.This is independent of #539, #554 and #563.
Written with the help of Claude (AI).
🤖 Generated with Claude Code
@KoLolX3 on GitHub · 2026-11-24 05:32 UTC · original
Check on Linux, not Windows: pass. Head
c249f02ddmerged ontomaind2a4bae1f(clean merge).core,formats,game,loader,pe,pipeline,shader): PR92 passed, 7 failed,main92 passed, 7 failed.cargo xwin check --workspace --target x86_64-pc-windows-msvc, coversvictory-gpu,victory-hleand the app): PR ok,mainok.main168.mainhere as well (not this PR): 7 tests invictory-loaderandvictory-pethat parse their own test binary as a PE image, which is an ELF file on Linux.victory-gpu/victory-hletests and the game itself.On: AMD Ryzen 7 5700, 62 GB RAM, Artix Linux 7.3.4-artix1-2, rustc 1.98.1 (the repo's pinned toolchain), cargo-xwin 0.24.1. No game data. Automated check only: the code itself was not reviewed.
@iurysf on GitHub · 2026-11-24 06:17 UTC · original
Tested offline against main
d2a4baewithvictory translate --list --validateover the title'sshaders.rpf+ executable (26,096 programs), dxil.dll 1.9.2602.17: emission is unchanged (3,733 failures, 12,284 emitted), and validation improves as claimed. The "Interpolation mode for PS input position ... oDepthGE/oDepthLE" rejections disappear (14 -> 0), vertex+pixel validated 12,184 -> 12,198, and total rejected 185 -> 171. No program that validated on main fails now.AI-assisted.
@slint6614-dev on GitHub · 2026-11-24 07:47 UTC · original
Measured on the full retail shader pack (26,503 containers) with
victory translate --validate, against maind2a4bae(emitted / validated). Windows 11, dxil.dll from SDK 10.0.26100.cargo test -p victory-shaderpasses on all four.