Support aligned render-XOR water texture readback #1331

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

@⁠cxy0072019-sketch on GitHub · 2026-11-26 15:46 UTC · original
cxy0072019-sketch:fix/aligned-render-xor-readback → main · +147 −11 · 2 files · 1 commits · open

Follow-up to #999. The CPU reads a tiled water height texture for buoyancy. A 256 × 256 R32_FLOAT plane in the render-XOR layout needs the console's pipe configuration to put the GPU's bytes back where the CPU expects them.

  • Support the aligned, single-mip SW_64KB_R_X plane on Series S and X. Keep the existing path for other addressable layouts and skip the GPU copy when the layout cannot be addressed.
  • Test both pipe configurations against independently generated digests of a synthetic plane. The test also covers padded rows, individual offsets, and the round trip through tiling and detiling. A GPU-layer regression test covers unsupported layouts and unaligned destinations.

On Windows, the clean branch passed 27 format tests and 218 GPU-layer tests. The staged asset-policy check passed for both files. With the same layout code in a separate native Series S integration build on an RTX 5070 Ti at 1920 × 1080, the first nonzero 262,144-byte plane copied back to guest memory byte for byte. The boat stayed afloat under player control. Small artifacts in water reflections remain.

**@⁠cxy0072019-sketch** on GitHub · 2026-11-26 15:46 UTC · [original](https://github.com/fxceless/victory-fork/pull/1331) `cxy0072019-sketch:fix/aligned-render-xor-readback` → `main` · +147 −11 · 2 files · 1 commits · open Follow-up to #999. The CPU reads a tiled water height texture for buoyancy. A 256 × 256 R32_FLOAT plane in the render-XOR layout needs the console's pipe configuration to put the GPU's bytes back where the CPU expects them. - Support the aligned, single-mip `SW_64KB_R_X` plane on Series S and X. Keep the existing path for other addressable layouts and skip the GPU copy when the layout cannot be addressed. - Test both pipe configurations against independently generated digests of a synthetic plane. The test also covers padded rows, individual offsets, and the round trip through tiling and detiling. A GPU-layer regression test covers unsupported layouts and unaligned destinations. On Windows, the clean branch passed 27 format tests and 218 GPU-layer tests. The staged asset-policy check passed for both files. With the same layout code in a separate native Series S integration build on an RTX 5070 Ti at 1920 × 1080, the first nonzero 262,144-byte plane copied back to guest memory byte for byte. The boat stayed afloat under player control. Small artifacts in water reflections remain.
Use the Series S or Series X render pipe equation for the supported single-mip R32 plane. Skip GPU copies for layouts the CPU cannot address. Compare both layouts against independently generated synthetic output.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-26 15:46:44 +00:00
Author
Owner

@⁠rafaconvaitis on GitHub · 2026-11-26 16:57 UTC · original

I reproduced a successful helm transfer with this layout code on an RTX 4070 12 GB, Windows and Series S, starting from a copied post-robbery checkpoint. The Cool Fox integration included the layout and destination changes from this PR, with the existing tiled-layout bounds preserved.

In Gone Fishing, Jason took the helm with Y. RT accelerated the boat and left a visible wake with Cal aboard. The HUD reached Collect the package. The log reported repeated successful 256 KiB texture readbacks and zero unsupported-tiling warnings in the observed boat segment. The two focused layout and destination tests pass on the Cool Fox backport branch. I opened the focused backport there. https://github.com/DoubleGhosty/cool_fox/pull/21

The first 60 s at the helm had a 13.5 FPS median (73.9 ms). This measures the integrated build. Some reflections and missing draws are still visible.

**@⁠rafaconvaitis** on GitHub · 2026-11-26 16:57 UTC · [original](https://github.com/fxceless/victory-fork/pull/1331#issuecomment-7198314095) I reproduced a successful helm transfer with this layout code on an RTX 4070 12 GB, Windows and Series S, starting from a copied post-robbery checkpoint. The Cool Fox integration included the layout and destination changes from this PR, with the existing tiled-layout bounds preserved. In Gone Fishing, Jason took the helm with Y. RT accelerated the boat and left a visible wake with Cal aboard. The HUD reached **Collect the package**. The log reported repeated successful 256 KiB texture readbacks and zero unsupported-tiling warnings in the observed boat segment. The two focused layout and destination tests pass on the Cool Fox backport branch. I opened the focused backport there. https://github.com/DoubleGhosty/cool_fox/pull/21 The first 60 s at the helm had a 13.5 FPS median (73.9 ms). This measures the integrated build. Some reflections and missing draws are still visible.
This pull request can be merged automatically.
This branch is out-of-date with the base branch
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/1331/head:github-bot/gh-1331'
git switch 'github-bot/gh-1331'

Merge

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