Skip to content

Commit

Permalink
Enable WGPU texture sampling test (#5617)
Browse files Browse the repository at this point in the history
* Limit number of MIP levels on 1d textures to be 1

This avoids running into a WebGPU limitation, and helps to address issue #4943.

* Update Slang-RHI to get WGPU fixes

* Enable WGPU texture sampling test

This helps to address issue #4943.

---------

Co-authored-by: Yong He <[email protected]>
  • Loading branch information
aleino-nv and csyonghe authored Nov 20, 2024
1 parent 00765c3 commit eb4ee72
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion external/slang-rhi
7 changes: 3 additions & 4 deletions tests/compute/texture-sampling-no-1d-arrays.slang
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
//TEST(compute):COMPARE_RENDER_COMPUTE: -shaderobj -output-using-type -mtl


//TEST_INPUT: Texture1D(size=4, content = one):name=t1D
// WebGPU only supports 1 MIP level for 1d textures
// https://www.w3.org/TR/webgpu/#abstract-opdef-maximum-miplevel-count
//TEST_INPUT: Texture1D(size=4, content = one, mipMaps=1):name=t1D
//TEST_INPUT: Texture2D(size=4, content = one):name=t2D
//TEST_INPUT: Texture3D(size=4, content = one):name=t3D
//TEST_INPUT: TextureCube(size=4, content = one):name=tCube
Expand All @@ -12,9 +14,6 @@
//TEST_INPUT: Sampler:name=samplerState
//TEST_INPUT: ubuffer(data=[0 0 0 0], stride=4):out,name=outputBuffer

// There are still some issues to fix in RHI, see issue #4943
//DISABLE_TEST(compute):COMPARE_COMPUTE:-slang -shaderobj -wgpu

Texture1D t1D;
Texture2D t2D;
Texture3D t3D;
Expand Down

0 comments on commit eb4ee72

Please sign in to comment.