Shaders: interpolation modes from the console container's PSV0 #150
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!150
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-150"
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?
@wildheathen on GitHub · 2026-11-24 21:54 UTC · original
wildheathen:interp-from-psv0→main· +176 −5 · 1 files · 1 commits · openThe interpolation modes of interpolated elements came from DXC's defaults by type: float linear, uint constant. But the console's compiler packs a float and a uint into one signature row and declares both constant in its PSV0. So the defaults mixed modes within one row, and
dxil.dllrefused the shader: "signature element … has interpolation mode that differs from another element packed into the same row". This reads the modes from the console container's PSV0, by row and column, and falls back to the defaults when there's no PSV0.It's the interpolation part of Marvisak/VIctory#1208 by @powplusplus, kept under their authorship, with its test. The only adaptation is the
geometryfield this fork added toPsv. #1208's other two parts are covered here already: the PSV0 string table by #61, the ISG1/OSG1 row order by #110 / #112.Measured
victory translate --validate --listovershaders.rpf, fork4e17478, dxil.dll 10.0.26100:4e174784e17478fails with this PR, alone or with #112. The +61 are 31 pixel, 17 mesh and 13 vertex programs.Checks
cargo test -p victory-shader: 211 passed.console_psv_interpolation_modes_are_preserved_for_copacked_inputs(from #1208) fails on4e17478with mode 2, linear, where the console says 1, constant, and passes here.cargo clippy -p victory-shader --all-targets -- -D warnings: clean.cargo xtask policy: ok.cargo fmt --checkreports nothing inemit/mod.rs.The modes of interpolated elements came from DXC's defaults by type (float: linear, uint: constant), but the console's compiler may pack a float and a uint element into one signature row, declaring both constant in its PSV0. Mixed modes in one row are rejected by the validator ("interpolation mode that differs from another element packed into the same row"). The modes are now read from the console container's PSV0, keyed by row and column, falling back to the defaults without one. Ported from Marvisak/VIctory#1208 (its interpolation-mode part and its test), adapted to this fork's Psv (`geometry`).@Parakeet-Wheat on GitHub · 2026-11-24 23:14 UTC · original
Reproduced the table on a second machine, and checked how this combines with #110 / #112 / #124 when merging.
610.88), Ryzen 5 5600X, Rust 1.98.1 (x86_64-pc-windows-msvc),dxil.dll1.8.2502, title 1.0.2.1; each PR merged onto2119b0e.victory translate <exe> shaders.rpf --list --validate, program by program against2119b0e(25,382 validated): this PR +61, #110 / #112 / #124 +72 each, this PR + #112 +139; 0 lost in every case. #110, #112 and #124 gain the same 72 programs (0 differences between any pair).cargo test -p victory-shader --locked: 211 passed, 0 failed, 2 ignored (this PR); 212 / 0 / 2 with #112.emit/mod.rs, where both add a test at the same spot (keep both tests).Offline translation and validation only; no shader contents or extracted data included. AI-assisted (Claude Code); run on my machine.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.