Repository navigation
Conversation
Array SRVs already encode the minimum LOD in the T#, but the sampled Vulkan view ignored the field and fetched a more detailed mip. Use the same resource-relative clamp as the existing 2D path and check both exposed layers against distinct mip colors.
Contributor
|
Tested cd04c7c on Windows 11, MSVC 14.51 (full shader toolchain): ctest 33/33 on an RTX 4080 SUPER (32.0.16.1714). On an Intel UHD 770 (32.0.101.6129) it's 32/33. The one failure is |
Keep the array minimum-LOD views in independent descriptor slots so the combined sampling checks exercise all view types.
2 tasks done
Contributor
Author
|
Replaced by #1015 following the current-main rebase request. The replacement contains one commit on |
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.
Claimed in the coordination issue as sampled Texture2DArray SRV minimum LOD.
What and why
A D3D12
Texture2DArraySRV encodedResourceMinLODClampin its T#, but the sampled Vulkan view ignored it. A draw or dispatch requesting LOD zero could see a more detailed mip than the application allowed. Single-sampled colour 2D-array views now use the resource-relative minimum LOD handling that #829 added for 2D. This keeps the array layer range, sampler and component mapping in place and uses the existing fallback when an effective in-range clamp needs an unavailable feature.Tested
Added distinct colours to a three-layer, three-mip RGBA8 array in
d3d12_descriptor_test. The view starts at resource mip 1 and layer 1. Through set 0, one sampler requests LOD 0 from both exposed layers. On Windows 11 build 26200, the RTX 5080 (32.0.16.1692) and AMD Radeon Graphics (32.0.21045.16010) gave these RGBA8 results:067d3e8with the new test: both GPUs returned (100,100,64,255) for the first layer at 1.75. The independent native D3D12 reference returned (100,180,64,255).Texture2DArray.SampleLevelreadback gave the same 192/192 on native D3D12 RTX, Radeon and WARP.d3d12_descriptor_testpassed on both Vulkan adapters andctest --no-tests=error -R '^d3d12_vulkan_device$'passed on RTX.Checklist
docs/d3d12_vulkan.md. This change uses the existing translator bindings.AI-assisted contribution using OpenAI Codex.