diff options
| author | Yong He <yonghe@outlook.com> | 2024-07-19 11:49:42 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-19 11:49:42 -0700 |
| commit | f114433debfba67cbe1db239b6e92278d41ed438 (patch) | |
| tree | 3a8ff78deb657d203c87bd22bc2ee83575e834f6 /source/slang/slang-reflection-api.cpp | |
| parent | adf758c8c4032afcd96d995840bd697d2adef34c (diff) | |
Support parameter block in metal shader objects. (#4671)
* Support parameter block in metal shader objects.
* Ingore parameter block tests on devices without tier2 argument buffer.
* Fix warning.
* Fix texture subscript test.
---------
Co-authored-by: Yong He <yhe@nvidia.com>
Diffstat (limited to 'source/slang/slang-reflection-api.cpp')
| -rw-r--r-- | source/slang/slang-reflection-api.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/source/slang/slang-reflection-api.cpp b/source/slang/slang-reflection-api.cpp index 9e08330e4..8dc889c97 100644 --- a/source/slang/slang-reflection-api.cpp +++ b/source/slang/slang-reflection-api.cpp @@ -810,13 +810,13 @@ SLANG_API SlangReflectionType * spReflection_FindTypeByName(SlangReflection * re SLANG_API SlangReflectionTypeLayout* spReflection_GetTypeLayout( SlangReflection* reflection, SlangReflectionType* inType, - SlangLayoutRules /*rules*/) + SlangLayoutRules rules) { auto context = convert(reflection); auto type = convert(inType); auto targetReq = context->getTargetReq(); - auto typeLayout = targetReq->getTypeLayout(type); + auto typeLayout = targetReq->getTypeLayout(type, (slang::LayoutRules)rules); return convert(typeLayout); } @@ -1875,6 +1875,7 @@ namespace Slang case LayoutResourceKind::DescriptorTableSlot: case LayoutResourceKind::Uniform: case LayoutResourceKind::ConstantBuffer: // for metal + case LayoutResourceKind::MetalArgumentBufferElement: resInfo = info; break; } |
