diff options
| author | Simon Kallweit <64953474+skallweitNV@users.noreply.github.com> | 2024-09-30 19:24:01 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-30 10:24:01 -0700 |
| commit | bc11579dd998224bcb429d88aeb07d49e2217a35 (patch) | |
| tree | ff6402940a1e2177407f7051d2375b2bee53adee /tools/render-test/shader-renderer-util.cpp | |
| parent | 59168f41f43d80650f3c02f5a840becead784ebc (diff) | |
Update slang-rhi (#5187)
* update slang-rhi
* fix render-test
* update slang-rhi
---------
Co-authored-by: Yong He <yonghe@outlook.com>
Diffstat (limited to 'tools/render-test/shader-renderer-util.cpp')
| -rw-r--r-- | tools/render-test/shader-renderer-util.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tools/render-test/shader-renderer-util.cpp b/tools/render-test/shader-renderer-util.cpp index 5448979b4..19bbbd2a5 100644 --- a/tools/render-test/shader-renderer-util.cpp +++ b/tools/render-test/shader-renderer-util.cpp @@ -73,7 +73,7 @@ inline int calcNumMipLevels(TextureType type, Extents size) textureDesc.sampleCount = inputDesc.sampleCount; textureDesc.format = format; - textureDesc.numMipLevels = texData.m_mipLevels; + textureDesc.mipLevelCount = texData.m_mipLevels; textureDesc.arrayLength = inputDesc.arrayLength > 0 ? inputDesc.arrayLength : 1; textureDesc.usage = TextureUsage::CopyDestination | TextureUsage::CopySource; switch (defaultState) @@ -119,9 +119,9 @@ inline int calcNumMipLevels(TextureType type, Extents size) } } - if (textureDesc.numMipLevels == 0) + if (textureDesc.mipLevelCount == 0) { - textureDesc.numMipLevels = calcNumMipLevels(textureDesc.type, textureDesc.size); + textureDesc.mipLevelCount = calcNumMipLevels(textureDesc.type, textureDesc.size); } List<SubresourceData> initSubresources; @@ -129,7 +129,7 @@ inline int calcNumMipLevels(TextureType type, Extents size) int subResourceCounter = 0; for( int a = 0; a < arrayLayerCount; ++a ) { - for( int m = 0; m < textureDesc.numMipLevels; ++m ) + for( int m = 0; m < textureDesc.mipLevelCount; ++m ) { int subResourceIndex = subResourceCounter++; const int mipWidth = calcMipSize(textureDesc.size.width, m); |
