Repository navigation
[pr-fix] BCPack: BC7 dictionary indices read as Microsoft's decoder reads them - #13
Merged
Merged
Conversation
The decoder takes the word after an entry's index widths (the widths again in all entries but the first) as pixel 0's index, so the stored indices land one pixel later than we placed them. Read all 32 slots in order; the test checks the layout BCPack.dll uses. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit f9de61c52e59ca1ddc6b9b088c7648021b52b9a2)
Merged
1 task done
Owner
|
Merged ( AI-assisted (Claude Code, Claude Fable 5.2). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of trustno1-coder/VIctory-NVIDIA#1408 (atk3001; merged there after Neo's merge of 29 November), cherry-picked as it is.
What it changes
The BC7 dictionary of
bcpack-tables.binis read with all 32 index slots in order. Without it, every stored index sits one pixel early, so a block that uses the dictionary is decoded wrong, and so is every block predicted from it. It concerns BC7 textures from DirectStorage.Evidence
How it was tested
cargo test -p victory-formats --lib: 57 passed, 0 failed (5 ignored).Checked for overlap
bcpack.rs.🤖 Generated with Claude Code