tests: read back startup image_get_lod through static sampler and mip view limits #2342

Manually merged
github merged 2 commits from gh-pr/2342/head into gh-pr/2342/base 2026-11-27 00:17:36 +00:00
Owner

@⁠RavenCurseBurg on GitHub · 2026-11-25 12:54 UTC · original
RavenCurseBurg:tests/startup-get-lod-view-readback → main · +164 −8 · 6 files · 2 commits · merged 2026-11-25 13:27 UTC

Follows up on the static sampler and SRV window questions in #2311. The new WARP and hardware CTests run the synthetic gfx1013 pixel stage through the actual smpl manifest and root signature. They compare it with an independent HLSL shader on the same 4×4, three-mip texture.

  • Seven cases cover four SRV windows, point and linear mip filtering, a fractional MaxLOD, and a fractional MinLOD with a negative raw LOD. Both shaders must return the same four binary32 words. The numerical reference allows one LOD step (1/256).
  • On a view starting at mip 1, exposing two mips returns (1, 1) and exposing one returns (0, 1). A linear MaxLOD of 0.75 returns (0.75, 2). Replacing only smpl with smp must restore (2, 2).
  • The new --startup-image-2d-view operation uses the existing texture upload and translated static sampler path and reports one pixel as four hex words.

Verification

  • At 9e5361b1, all four selected Windows CTests passed with zero skips, including the new WARP test, the existing GET_LOD host controls, the 2D-array WARP test and the sample-LOD WARP test. WARP reported zero debug-layer warnings and errors. Pinned Windows build and test log
  • I then ran this PR's test and the same source-stamped renderer on Windows 11 24H2 build 26100.9711. WARP (10.0.26100.9711), RTX 4060 (32.0.15.9579) and UHD 770 (32.0.101.5973) each passed seven translated/direct pairs and the ordinary-sampler control. All 45 draws returned a pixel. The local debug layer was unavailable.
  • Six local host and documentation checks passed. I also tested 12 translated/direct pairs per adapter and the manifest control on RTX 4060, UHD 770 and WARP using the measurement fixture. Exact point-filter half-mip boundaries selected different neighbors on Intel and on WARP/NVIDIA. The regression checks the fractional lower clamp with linear filtering. Readbacks, versions and replay script

The measurement covers desktop D3D12. Native console sampler/view equivalence remains open.

Agent environment and model: Codex + GPT-6.2 Astra xhigh.

**@⁠RavenCurseBurg** on GitHub · 2026-11-25 12:54 UTC · [original](https://github.com/R0Y00/Xbox2Windows/pull/2342) `RavenCurseBurg:tests/startup-get-lod-view-readback` → `main` · +164 −8 · 6 files · 2 commits · merged 2026-11-25 13:27 UTC Follows up on the static sampler and SRV window questions in #2311. The new WARP and hardware CTests run the synthetic gfx1013 pixel stage through the actual `smpl` manifest and root signature. They compare it with an independent HLSL shader on the same 4×4, three-mip texture. - Seven cases cover four SRV windows, point and linear mip filtering, a fractional MaxLOD, and a fractional MinLOD with a negative raw LOD. Both shaders must return the same four binary32 words. The numerical reference allows one LOD step (1/256). - On a view starting at mip 1, exposing two mips returns (1, 1) and exposing one returns (0, 1). A linear MaxLOD of 0.75 returns (0.75, 2). Replacing only `smpl` with `smp` must restore (2, 2). - The new `--startup-image-2d-view` operation uses the existing texture upload and translated static sampler path and reports one pixel as four hex words. **Verification** - At 9e5361b1, all four selected Windows CTests passed with zero skips, including the new WARP test, the existing GET_LOD host controls, the 2D-array WARP test and the sample-LOD WARP test. WARP reported zero debug-layer warnings and errors. [Pinned Windows build and test log](https://github.com/RavenCurseBurg/Xbox2Windows/actions/runs/45618417407) - I then ran this PR's test and the same source-stamped renderer on Windows 11 24H2 build 26100.9711. WARP (10.0.26100.9711), RTX 4060 (32.0.15.9579) and UHD 770 (32.0.101.5973) each passed seven translated/direct pairs and the ordinary-sampler control. All 45 draws returned a pixel. The local debug layer was unavailable. - Six local host and documentation checks passed. I also tested 12 translated/direct pairs per adapter and the manifest control on RTX 4060, UHD 770 and WARP using the measurement fixture. Exact point-filter half-mip boundaries selected different neighbors on Intel and on WARP/NVIDIA. The regression checks the fractional lower clamp with linear filtering. [Readbacks, versions and replay script](https://git.gtahub.st/github/R0Y00--Xbox2Windows/pulls/2311) The measurement covers desktop D3D12. Native console sampler/view equivalence remains open. Agent environment and model: Codex + GPT-6.2 Astra xhigh.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-27 00:17:34 +00:00
github manually merged commit 9e5361b127 into gh-pr/2342/base 2026-11-27 00:17:36 +00:00
This discussion has been locked. Commenting is limited to contributors.
No description provided.