shader: fix BCPack, VOP1, DXBC and console texture formats #15

Open
github-bot wants to merge 1 commit from github-bot/gh-15 into main AGit
Owner

@⁠davutsimsekk on GitHub · 2026-11-25 19:04 UTC · original
davutsimsekk:fix/shader-format-edges → main · +90 −9 · 4 files · 1 commits · open

Fixes four parser and format edge cases found by comparing the runtime with the upstream Victory fixes.

  • BCPack reads all 32 BC7 indices for dictionary entry 0; later entries still repeat their width bytes.
  • VOP1 no-source ops (v_nop, v_pipeflush, v_clrexcp) stay one dword and no longer consume a literal.
  • DXBC rejects a part offset that points inside the header or the part table.
  • The texture format table accepts console formats 189/190/191 with 4/1/4-byte elements, matching the GPU resource table.

Tested

  • cargo test -p victory-formats --lib --locked: 27 passed, 4 ignored.
  • cargo test -p victory-shader --lib --locked: 217 passed, 3 ignored.
  • Windows 11, Rust 1.98.1, locked offline build.

Not tested

  • No in-game run; no game files or console dump was used.

AI use

  • Automated coding agent for analysis, patch preparation and test runs.
**@⁠davutsimsekk** on GitHub · 2026-11-25 19:04 UTC · [original](https://github.com/rpatty-dev/PercyScarlett/pull/15) `davutsimsekk:fix/shader-format-edges` → `main` · +90 −9 · 4 files · 1 commits · open Fixes four parser and format edge cases found by comparing the runtime with the upstream Victory fixes. - BCPack reads all 32 BC7 indices for dictionary entry 0; later entries still repeat their width bytes. - VOP1 no-source ops (`v_nop`, `v_pipeflush`, `v_clrexcp`) stay one dword and no longer consume a literal. - DXBC rejects a part offset that points inside the header or the part table. - The texture format table accepts console formats 189/190/191 with 4/1/4-byte elements, matching the GPU resource table. **Tested** - `cargo test -p victory-formats --lib --locked`: 27 passed, 4 ignored. - `cargo test -p victory-shader --lib --locked`: 217 passed, 3 ignored. - Windows 11, Rust 1.98.1, locked offline build. **Not tested** - No in-game run; no game files or console dump was used. **AI use** - Automated coding agent for analysis, patch preparation and test runs.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 02:22:09 +00:00
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/15/head:github-bot/gh-15'
git switch 'github-bot/gh-15'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-15'
git switch 'github-bot/gh-15'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-15'
git switch 'github-bot/gh-15'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-15'
git switch 'main'
git merge --squash 'github-bot/gh-15'
git switch 'main'
git merge --ff-only 'github-bot/gh-15'
git switch 'main'
git merge 'github-bot/gh-15'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.