Formats: support console texture formats 189–191 in texture layouts #11

Manually merged
github merged 2 commits from gh-pr/11/head into gh-pr/11/base 2026-11-26 03:40:48 +00:00
Owner

@⁠Yoshi-233 on GitHub · 2026-11-25 06:25 UTC · original
Yoshi-233:backport/console-texture-formats → main · +23 −2 · 1 files · 2 commits · merged 2026-11-25 09:49 UTC

The GPU resource table already assigns byte sizes to console formats 189, 190 and 191. The format table used by Texture::new omitted them, so layout creation returned Error::Invalid for all three.

The first commit backports @⁠davutsimsekk's format mapping from fxceless/victory-fork#735. Formats 189 and 191 use four bytes per texel, and format 190 uses one. The second commit tests the public Texture::new entry point against RGBA8 and R8 reference layouts, including the mip and array layout.

On native Linux, I tested a synthetic 257 × 129 texture with four mip levels and two array slices in both linear and 64 KiB tiled layouts. All six cases returned Invalid on b8634af and matched their reference layouts on this branch. cargo test --locked -p victory-formats --lib passed with 26 tests passed and four ignored. This verifies CPU-side layout calculation. Actual rendering remains to be tested.

**@⁠Yoshi-233** on GitHub · 2026-11-25 06:25 UTC · [original](https://github.com/uiliannn/VItoriaBr/pull/11) `Yoshi-233:backport/console-texture-formats` → `main` · +23 −2 · 1 files · 2 commits · merged 2026-11-25 09:49 UTC The GPU resource table already assigns byte sizes to console formats 189, 190 and 191. The format table used by `Texture::new` omitted them, so layout creation returned `Error::Invalid` for all three. The first commit backports @⁠davutsimsekk's format mapping from fxceless/victory-fork#735. Formats 189 and 191 use four bytes per texel, and format 190 uses one. The second commit tests the public `Texture::new` entry point against RGBA8 and R8 reference layouts, including the mip and array layout. On native Linux, I tested a synthetic 257 × 129 texture with four mip levels and two array slices in both linear and 64 KiB tiled layouts. All six cases returned `Invalid` on `b8634af` and matched their reference layouts on this branch. `cargo test --locked -p victory-formats --lib` passed with 26 tests passed and four ignored. This verifies CPU-side layout calculation. Actual rendering remains to be tested.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 03:40:45 +00:00
github manually merged commit dcc0305cad into gh-pr/11/base 2026-11-26 03:40:48 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.