diff options
| author | Yong He <yonghe@outlook.com> | 2024-04-15 23:28:28 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-04-15 23:28:28 -0700 |
| commit | 3192f34f57abd3245995342a0a5971ebbbbd945c (patch) | |
| tree | dc139be9fe9f4995bac96513571cc9e0526ce547 /slang.h | |
| parent | 030d7f45726187b5b23a3cfb9743166aa60fae30 (diff) | |
[GFX] Fix d3d12 buffer view creation logic for StructuredBuffers. (#3954)
Diffstat (limited to 'slang.h')
| -rw-r--r-- | slang.h | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -2390,6 +2390,7 @@ extern "C" SLANG_API size_t spReflectionTypeLayout_GetStride(SlangReflectionTypeLayout* type, SlangParameterCategory category); SLANG_API int32_t spReflectionTypeLayout_getAlignment(SlangReflectionTypeLayout* type, SlangParameterCategory category); + SLANG_API uint32_t spReflectionTypeLayout_GetFieldCount(SlangReflectionTypeLayout* type); SLANG_API SlangReflectionVariableLayout* spReflectionTypeLayout_GetFieldByIndex(SlangReflectionTypeLayout* type, unsigned index); SLANG_API SlangInt spReflectionTypeLayout_findFieldIndexByName(SlangReflectionTypeLayout* typeLayout, const char* nameBegin, const char* nameEnd); @@ -2884,7 +2885,7 @@ namespace slang unsigned int getFieldCount() { - return getType()->getFieldCount(); + return spReflectionTypeLayout_GetFieldCount((SlangReflectionTypeLayout*)this); } VariableLayoutReflection* getFieldByIndex(unsigned int index) |
