4#ifdef SLANG_USER_CONFIG
5 #include SLANG_USER_CONFIG
24 #define SLANG_COMPILER
33 #elif _MSC_VER >= 1800
35 #elif _MSC_VER >= 1700
37 #elif _MSC_VER >= 1600
39 #elif _MSC_VER >= 1500
42 #error "unknown version of Visual C++ compiler"
44 #elif defined(__clang__)
46 #elif defined(__SNC__)
48 #elif defined(__ghs__)
50 #elif defined(__GNUC__)
53 #error "unknown compiler"
85 #define SLANG_PLATFORM
89 #if defined(WINAPI_FAMILY) && WINAPI_FAMILY == WINAPI_PARTITION_APP
91 #elif defined(XBOXONE)
92 #define SLANG_XBOXONE 1
99 #elif defined(__ANDROID__)
100 #define SLANG_ANDROID 1
101 #elif defined(__linux__) || defined(__CYGWIN__)
102 #define SLANG_LINUX 1
103 #elif defined(__APPLE__)
104 #include "TargetConditionals.h"
110 #elif defined(__CELLOS_LV2__)
112 #elif defined(__ORBIS__)
114 #elif defined(__SNC__) && defined(__arm__)
116 #elif defined(__ghs__)
118 #elif defined(__EMSCRIPTEN__)
121 #error "unknown target platform"
127 #define SLANG_WINRT 0
129 #ifndef SLANG_XBOXONE
130 #define SLANG_XBOXONE 0
133 #define SLANG_WIN64 0
139 #define SLANG_WIN32 0
141 #ifndef SLANG_ANDROID
142 #define SLANG_ANDROID 0
145 #define SLANG_LINUX 0
171#define SLANG_GCC_FAMILY (SLANG_CLANG || SLANG_SNC || SLANG_GHS || SLANG_GCC)
172#define SLANG_WINDOWS_FAMILY (SLANG_WINRT || SLANG_WIN32 || SLANG_WIN64)
173#define SLANG_MICROSOFT_FAMILY (SLANG_XBOXONE || SLANG_X360 || SLANG_WINDOWS_FAMILY)
174#define SLANG_LINUX_FAMILY (SLANG_LINUX || SLANG_ANDROID)
175#define SLANG_APPLE_FAMILY (SLANG_IOS || SLANG_OSX)
176#define SLANG_UNIX_FAMILY \
177 (SLANG_LINUX_FAMILY || SLANG_APPLE_FAMILY)
180#if !defined(SLANG_CONFIG_DX_ON_VK) || !SLANG_CONFIG_DX_ON_VK
181 #define SLANG_ENABLE_DXVK 0
182 #define SLANG_ENABLE_VKD3D 0
184 #define SLANG_ENABLE_DXVK 1
185 #define SLANG_ENABLE_VKD3D 1
188#if SLANG_WINDOWS_FAMILY
189 #define SLANG_ENABLE_DIRECTX 1
190 #define SLANG_ENABLE_DXGI_DEBUG 1
191 #define SLANG_ENABLE_DXBC_SUPPORT 1
192 #define SLANG_ENABLE_PIX 1
193#elif SLANG_LINUX_FAMILY
194 #define SLANG_ENABLE_DIRECTX (SLANG_ENABLE_DXVK || SLANG_ENABLE_VKD3D)
195 #define SLANG_ENABLE_DXGI_DEBUG 0
196 #define SLANG_ENABLE_DXBC_SUPPORT 0
197 #define SLANG_ENABLE_PIX 0
199 #define SLANG_ENABLE_DIRECTX 0
200 #define SLANG_ENABLE_DXGI_DEBUG 0
201 #define SLANG_ENABLE_DXBC_SUPPORT 0
202 #define SLANG_ENABLE_PIX 0
206#ifndef SLANG_NO_THROW
207 #if SLANG_WINDOWS_FAMILY && !defined(SLANG_DISABLE_EXCEPTIONS)
208 #define SLANG_NO_THROW __declspec(nothrow)
211#ifndef SLANG_NO_THROW
212 #define SLANG_NO_THROW
219 #if SLANG_MICROSOFT_FAMILY
220 #define SLANG_STDCALL __stdcall
222 #define SLANG_STDCALL
226 #define SLANG_MCALL SLANG_STDCALL
230#if !defined(SLANG_STATIC) && !defined(SLANG_DYNAMIC)
231 #define SLANG_DYNAMIC
235 #define SLANG_DLL_EXPORT __declspec(dllexport)
237 #if SLANG_WINDOWS_FAMILY
238 #define SLANG_DLL_EXPORT \
239 __attribute__((dllexport)) __attribute__((__visibility__("default")))
241 #define SLANG_DLL_EXPORT __attribute__((__visibility__("default")))
245#if defined(SLANG_DYNAMIC)
246 #if defined(_MSC_VER)
247 #ifdef SLANG_DYNAMIC_EXPORT
248 #define SLANG_API SLANG_DLL_EXPORT
250 #define SLANG_API __declspec(dllimport)
255 #define SLANG_API SLANG_DLL_EXPORT
266 #define SLANG_NO_INLINE __attribute__((noinline))
267 #define SLANG_FORCE_INLINE inline __attribute__((always_inline))
268 #define SLANG_BREAKPOINT(id) __builtin_trap();
271#if SLANG_GCC_FAMILY || defined(__clang__)
273 #define SLANG_OFFSET_OF(T, ELEMENT) __builtin_offsetof(T, ELEMENT)
276#ifndef SLANG_OFFSET_OF
277 #define SLANG_OFFSET_OF(T, ELEMENT) (size_t(&((T*)1)->ELEMENT) - 1)
282 #define SLANG_NO_INLINE __declspec(noinline)
283 #define SLANG_FORCE_INLINE __forceinline
284 #define SLANG_BREAKPOINT(id) __debugbreak();
286 #define SLANG_INT64(x) (x##i64)
287 #define SLANG_UINT64(x) (x##ui64)
290#ifndef SLANG_FORCE_INLINE
291 #define SLANG_FORCE_INLINE inline
293#ifndef SLANG_NO_INLINE
294 #define SLANG_NO_INLINE
297#ifndef SLANG_COMPILE_TIME_ASSERT
298 #define SLANG_COMPILE_TIME_ASSERT(x) static_assert(x)
301#ifndef SLANG_BREAKPOINT
303 #define SLANG_BREAKPOINT(id) (*((int*)0) = int(id));
308#define SLANG_COUNT_OF(x) (SlangSSizeT(sizeof(x) / sizeof(0 [x])))
310#define SLANG_INLINE inline
313#if !defined(SLANG_HAS_EXCEPTIONS) && defined(SLANG_DISABLE_EXCEPTIONS)
314 #define SLANG_HAS_EXCEPTIONS 0
318#ifndef SLANG_HAS_EXCEPTIONS
319 #define SLANG_HAS_EXCEPTIONS 1
323#define SLANG_STRINGIZE_HELPER(X) #X
324#define SLANG_STRINGIZE(X) SLANG_STRINGIZE_HELPER(X)
326#define SLANG_CONCAT_HELPER(X, Y) X##Y
327#define SLANG_CONCAT(X, Y) SLANG_CONCAT_HELPER(X, Y)
330 #define SLANG_UNUSED(v) (void)v;
334 #define SLANG_MAYBE_UNUSED [[maybe_unused]]
336 #define SLANG_MAYBE_UNUSED
341 #define SLANG_INT64(x) (x##ll)
344 #define SLANG_UINT64(x) (x##ull)
349 #define SLANG_EXTERN_C extern "C"
351 #define SLANG_EXTERN_C
358 #if (__clang_major__ * 10 + __clang_minor__) >= 33
359 #define SLANG_HAS_MOVE_SEMANTICS 1
360 #define SLANG_HAS_ENUM_CLASS 1
361 #define SLANG_OVERRIDE override
365 #elif SLANG_GCC_FAMILY
367 #if (__cplusplus >= 201103L)
368 #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 405
369 #define SLANG_HAS_MOVE_SEMANTICS 1
371 #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 406
372 #define SLANG_HAS_ENUM_CLASS 1
374 #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 407
375 #define SLANG_OVERRIDE override
385 #pragma warning(disable : 4481)
387 #define SLANG_OVERRIDE override
389 #define SLANG_HAS_MOVE_SEMANTICS 1
392 #define SLANG_HAS_ENUM_CLASS 1
397 #ifndef SLANG_OVERRIDE
398 #define SLANG_OVERRIDE
400 #ifndef SLANG_HAS_ENUM_CLASS
401 #define SLANG_HAS_ENUM_CLASS 0
403 #ifndef SLANG_HAS_MOVE_SEMANTICS
404 #define SLANG_HAS_MOVE_SEMANTICS 0
410#if defined(_M_ARM) || defined(__ARM_EABI__)
412 #define SLANG_PROCESSOR_ARM 1
413#elif defined(__i386__) || defined(_M_IX86)
414 #define SLANG_PROCESSOR_X86 1
415#elif defined(_M_AMD64) || defined(_M_X64) || defined(__amd64) || defined(__x86_64)
416 #define SLANG_PROCESSOR_X86_64 1
417#elif defined(_PPC_) || defined(__ppc__) || defined(__POWERPC__) || defined(_M_PPC)
418 #if defined(__powerpc64__) || defined(__ppc64__) || defined(__PPC64__) || \
419 defined(__64BIT__) || defined(_LP64) || defined(__LP64__)
420 #define SLANG_PROCESSOR_POWER_PC_64 1
422 #define SLANG_PROCESSOR_POWER_PC 1
424#elif defined(__arm__)
425 #define SLANG_PROCESSOR_ARM 1
426#elif defined(_M_ARM64) || defined(__aarch64__) || defined(__ARM_ARCH_ISA_A64)
427 #define SLANG_PROCESSOR_ARM_64 1
428#elif defined(__EMSCRIPTEN__)
429 #define SLANG_PROCESSOR_WASM 1
432#ifndef SLANG_PROCESSOR_ARM
433 #define SLANG_PROCESSOR_ARM 0
436#ifndef SLANG_PROCESSOR_ARM_64
437 #define SLANG_PROCESSOR_ARM_64 0
440#ifndef SLANG_PROCESSOR_X86
441 #define SLANG_PROCESSOR_X86 0
444#ifndef SLANG_PROCESSOR_X86_64
445 #define SLANG_PROCESSOR_X86_64 0
448#ifndef SLANG_PROCESSOR_POWER_PC
449 #define SLANG_PROCESSOR_POWER_PC 0
452#ifndef SLANG_PROCESSOR_POWER_PC_64
453 #define SLANG_PROCESSOR_POWER_PC_64 0
456#ifndef SLANG_PROCESSOR_WASM
457 #define SLANG_PROCESSOR_WASM 0
462#define SLANG_PROCESSOR_FAMILY_X86 (SLANG_PROCESSOR_X86_64 | SLANG_PROCESSOR_X86)
463#define SLANG_PROCESSOR_FAMILY_ARM (SLANG_PROCESSOR_ARM | SLANG_PROCESSOR_ARM_64)
464#define SLANG_PROCESSOR_FAMILY_POWER_PC (SLANG_PROCESSOR_POWER_PC_64 | SLANG_PROCESSOR_POWER_PC)
467#define SLANG_PTR_IS_64 \
468 (SLANG_PROCESSOR_ARM_64 | SLANG_PROCESSOR_X86_64 | SLANG_PROCESSOR_POWER_PC_64)
469#define SLANG_PTR_IS_32 (SLANG_PTR_IS_64 ^ 1)
472#if SLANG_PROCESSOR_FAMILY_X86
473 #define SLANG_LITTLE_ENDIAN 1
474 #define SLANG_UNALIGNED_ACCESS 1
475#elif SLANG_PROCESSOR_FAMILY_ARM
476 #if defined(__ARMEB__)
477 #define SLANG_BIG_ENDIAN 1
479 #define SLANG_LITTLE_ENDIAN 1
481#elif SLANG_PROCESSOR_FAMILY_POWER_PC
482 #define SLANG_BIG_ENDIAN 1
484 #define SLANG_LITTLE_ENDIAN 1
487#ifndef SLANG_LITTLE_ENDIAN
488 #define SLANG_LITTLE_ENDIAN 0
491#ifndef SLANG_BIG_ENDIAN
492 #define SLANG_BIG_ENDIAN 0
495#ifndef SLANG_UNALIGNED_ACCESS
496 #define SLANG_UNALIGNED_ACCESS 0
500#if SLANG_LINUX_FAMILY
501 #include <features.h>
502 #if defined(__GLIBC__) || (__ANDROID_API__ >= 33)
503 #define SLANG_HAS_BACKTRACE 1
505 #define SLANG_HAS_BACKTRACE 0
508 #define SLANG_HAS_BACKTRACE 0
512#if ((SLANG_BIG_ENDIAN | SLANG_LITTLE_ENDIAN) == 0)
513 #error "Couldn't determine endianness"
516#ifndef SLANG_NO_INTTYPES
517 #include <inttypes.h>
520#ifndef SLANG_NO_STDDEF
524#ifdef SLANG_NO_DEPRECATION
525 #define SLANG_DEPRECATED
527 #define SLANG_DEPRECATED [[deprecated]]
1247#define SLANG_FAILED(status) ((status) < 0)
1250#define SLANG_SUCCEEDED(status) ((status) >= 0)
1253#define SLANG_GET_RESULT_FACILITY(r) ((int32_t)(((r) >> 16) & 0x7fff))
1255#define SLANG_GET_RESULT_CODE(r) ((int32_t)((r) & 0xffff))
1257#define SLANG_MAKE_ERROR(fac, code) \
1258 ((((int32_t)(fac)) << 16) | ((int32_t)(code)) | int32_t(0x80000000))
1259#define SLANG_MAKE_SUCCESS(fac, code) ((((int32_t)(fac)) << 16) | ((int32_t)(code)))
1264#define SLANG_FACILITY_WIN_GENERAL 0
1265#define SLANG_FACILITY_WIN_INTERFACE 4
1266#define SLANG_FACILITY_WIN_API 7
1270#define SLANG_FACILITY_BASE 0x200
1275#define SLANG_FACILITY_CORE SLANG_FACILITY_BASE
1279#define SLANG_FACILITY_INTERNAL SLANG_FACILITY_BASE + 1
1282#define SLANG_FACILITY_EXTERNAL_BASE 0x210
1292#define SLANG_FAIL SLANG_MAKE_ERROR(SLANG_FACILITY_WIN_GENERAL, 0x4005)
1294#define SLANG_MAKE_WIN_GENERAL_ERROR(code) SLANG_MAKE_ERROR(SLANG_FACILITY_WIN_GENERAL, code)
1297#define SLANG_E_NOT_IMPLEMENTED SLANG_MAKE_WIN_GENERAL_ERROR(0x4001)
1299#define SLANG_E_NO_INTERFACE SLANG_MAKE_WIN_GENERAL_ERROR(0x4002)
1301#define SLANG_E_ABORT SLANG_MAKE_WIN_GENERAL_ERROR(0x4004)
1304#define SLANG_E_INVALID_HANDLE SLANG_MAKE_ERROR(SLANG_FACILITY_WIN_API, 6)
1306#define SLANG_E_INVALID_ARG SLANG_MAKE_ERROR(SLANG_FACILITY_WIN_API, 0x57)
1308#define SLANG_E_OUT_OF_MEMORY SLANG_MAKE_ERROR(SLANG_FACILITY_WIN_API, 0xe)
1312#define SLANG_MAKE_CORE_ERROR(code) SLANG_MAKE_ERROR(SLANG_FACILITY_CORE, code)
1315#define SLANG_E_BUFFER_TOO_SMALL SLANG_MAKE_CORE_ERROR(1)
1319#define SLANG_E_UNINITIALIZED SLANG_MAKE_CORE_ERROR(2)
1322#define SLANG_E_PENDING SLANG_MAKE_CORE_ERROR(3)
1324#define SLANG_E_CANNOT_OPEN SLANG_MAKE_CORE_ERROR(4)
1326#define SLANG_E_NOT_FOUND SLANG_MAKE_CORE_ERROR(5)
1328#define SLANG_E_INTERNAL_FAIL SLANG_MAKE_CORE_ERROR(6)
1330#define SLANG_E_NOT_AVAILABLE SLANG_MAKE_CORE_ERROR(7)
1332#define SLANG_E_TIME_OUT SLANG_MAKE_CORE_ERROR(8)
1356#define SLANG_COM_INTERFACE(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7) \
1358 SLANG_FORCE_INLINE constexpr static SlangUUID getTypeGuid() \
1360 return {a, b, c, d0, d1, d2, d3, d4, d5, d6, d7}; \
1365#define SLANG_CLASS_GUID(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7) \
1366 SLANG_FORCE_INLINE constexpr static SlangUUID getTypeGuid() \
1368 return {a, b, c, d0, d1, d2, d3, d4, d5, d6, d7}; \
1381#define SLANG_IID_PPV_ARGS(ppType) \
1382 std::decay_t<decltype(**(ppType))>::getTypeGuid(), \
1386 std::is_base_of_v<ISlangUnknown, std::decay_t<decltype(**(ppType))>>); \
1388 reinterpret_cast<void**>(ppType))
1403 {0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46})
1421#define SLANG_UUID_ISlangUnknown ISlangUnknown::getTypeGuid()
1432 {0x8b, 0xf2, 0xcb, 0x31, 0x87, 0x4d, 0xe2, 0x39});
1446 {0xbb, 0x17, 0x4, 0x8a, 0x80, 0x46, 0xb3, 0x1f});
1465 {0xAC, 0x58, 0x0D, 0x98, 0x9C, 0x3A, 0x01, 0x02})
1470#define SLANG_UUID_ISlangBlob ISlangBlob::getTypeGuid()
1481 {0xa7, 0x8b, 0xc4, 0x86, 0x84, 0x30, 0xdf, 0xbb});
1482 operator const char*()
const {
return chars; }
1503 {0xAD, 0x60, 0x1F, 0xD8, 0x63, 0xA9, 0x15, 0xAB})
1521#define SLANG_UUID_ISlangFileSystem ISlangFileSystem::getTypeGuid()
1535 {0x80, 0xd7, 0xd1, 0x47, 0xc4, 0xa2, 0x37, 0x30})
1539#define SLANG_UUID_ISlangSharedLibrary_Dep1 ISlangSharedLibrary_Dep1::getTypeGuid()
1550 {0xae, 0x7e, 0x75, 0x2a, 0xf6, 0xa8, 0x15, 0x55})
1567#define SLANG_UUID_ISlangSharedLibrary ISlangSharedLibrary::getTypeGuid()
1575 {0x97, 0xf1, 0x49, 0xbc, 0x2d, 0x2a, 0xb1, 0x4d})
1586#define SLANG_UUID_ISlangSharedLibraryLoader ISlangSharedLibraryLoader::getTypeGuid()
1658 {0x9f, 0xee, 0x66, 0x3c, 0x3f, 0x14, 0x49, 0xe1})
1708 const char* fromPath,
1748 void* userData) = 0;
1757#define SLANG_UUID_ISlangFileSystemExt ISlangFileSystemExt::getTypeGuid()
1765 {0x84, 0x58, 0xcc, 0xde, 0xd1, 0x42, 0x71, 0x5})
1776 saveFile(
const char* path,
const void*
data,
size_t size) = 0;
1813#define SLANG_UUID_ISlangMutableFileSystem ISlangMutableFileSystem::getTypeGuid()
1840 {0x85, 0x1c, 0xd7, 0xfa, 0x71, 0x6d, 0x15, 0xfd})
1861 write(
const char* chars,
size_t numChars) = 0;
1873#define SLANG_UUID_ISlangWriter ISlangWriter::getTypeGuid()
1881 {0x84, 0xe8, 0x66, 0x68, 0xba, 0xff, 0x06, 0x19})
1887#define SLANG_UUID_ISlangProfiler ISlangProfiler::getTypeGuid()
1891 struct IGlobalSession;
1892 struct ICompileRequest;
2040#ifndef SLANG_RESOURCE_SHAPE
2041 #define SLANG_RESOURCE_SHAPE
2277#define SLANG_FORMAT(NAME, DESC) SLANG_IMAGE_FORMAT_##NAME,
2282#define SLANG_UNBOUNDED_SIZE (~size_t(0))
2283#define SLANG_UNKNOWN_SIZE (SLANG_UNBOUNDED_SIZE - 1)
2307struct BufferReflection;
2308struct DeclReflection;
2309struct TypeLayoutReflection;
2310struct TypeReflection;
2311struct VariableLayoutReflection;
2312struct VariableReflection;
2313struct FunctionReflection;
2314struct GenericReflection;
2316union GenericArgReflection
2318 TypeReflection* typeVal;
2325 char const* getName()
2329 uint32_t getArgumentCount()
2334 TypeReflection* getArgumentType(uint32_t index)
2340 SlangResult getArgumentValueInt(uint32_t index,
int* value)
2347 SlangResult getArgumentValueFloat(uint32_t index,
float* value)
2354 const char* getArgumentValueString(uint32_t index,
size_t* outSize)
2363typedef Attribute UserAttribute;
2365struct TypeReflection
2418 unsigned int getFieldCount()
2423 VariableReflection* getFieldByIndex(
unsigned int index)
2429 bool isArray() {
return getKind() == TypeReflection::Kind::Array; }
2431 TypeReflection* unwrapArray()
2433 TypeReflection* type =
this;
2434 while (type->isArray())
2436 type = type->getElementType();
2460 size_t getTotalArrayElementCount()
2465 TypeReflection* type =
this;
2468 if (!type->isArray())
2471 const auto c = type->getElementCount();
2477 type = type->getElementType();
2481 TypeReflection* getElementType()
2488 unsigned getColumnCount()
2493 ScalarType getScalarType()
2498 TypeReflection* getResourceResultType()
2520 unsigned int getUserAttributeCount()
2525 UserAttribute* getUserAttributeByIndex(
unsigned int index)
2530 UserAttribute* findAttributeByName(
char const* name)
2537 UserAttribute* findUserAttributeByName(
char const* name) {
return findAttributeByName(name); }
2539 TypeReflection* applySpecializations(GenericReflection* generic)
2546 GenericReflection* getGenericContainer()
2623struct ShaderReflection;
2625struct TypeLayoutReflection
2627 TypeReflection* getType()
2632 TypeReflection::Kind getKind()
2671 size_t getSize(slang::ParameterCategory category = slang::ParameterCategory::Uniform)
2684 size_t getStride(slang::ParameterCategory category = slang::ParameterCategory::Uniform)
2691 int32_t getAlignment(slang::ParameterCategory category = slang::ParameterCategory::Uniform)
2699 unsigned int getFieldCount()
2704 VariableLayoutReflection* getFieldByIndex(
unsigned int index)
2711 SlangInt findFieldIndexByName(
char const* nameBegin,
char const* nameEnd =
nullptr)
2719 VariableLayoutReflection* getExplicitCounter()
2725 bool isArray() {
return getType()->isArray(); }
2727 TypeLayoutReflection* unwrapArray()
2729 TypeLayoutReflection* typeLayout =
this;
2730 while (typeLayout->isArray())
2732 typeLayout = typeLayout->getElementTypeLayout();
2745 size_t getElementCount(ShaderReflection* reflection =
nullptr)
2756 size_t getTotalArrayElementCount() {
return getType()->getTotalArrayElementCount(); }
2769 TypeLayoutReflection* getElementTypeLayout()
2775 VariableLayoutReflection* getElementVarLayout()
2781 VariableLayoutReflection* getContainerVarLayout()
2788 ParameterCategory getParameterCategory()
2794 unsigned int getCategoryCount()
2799 ParameterCategory getCategoryByIndex(
unsigned int index)
2806 unsigned getRowCount() {
return getType()->getRowCount(); }
2808 unsigned getColumnCount() {
return getType()->getColumnCount(); }
2810 TypeReflection::ScalarType getScalarType() {
return getType()->getScalarType(); }
2812 TypeReflection* getResourceResultType() {
return getType()->getResourceResultType(); }
2818 char const* getName() {
return getType()->getName(); }
2825 int getGenericParamIndex()
2831 [[deprecated]] TypeLayoutReflection* getPendingDataTypeLayout() {
return nullptr; }
2834 [[deprecated]] VariableLayoutReflection* getSpecializedTypePendingDataVarLayout()
2844 BindingType getBindingRangeType(
SlangInt index)
2851 bool isBindingRangeSpecializable(
SlangInt index)
2894 SlangInt getExplicitCounterBindingRangeOffset()
2900 TypeLayoutReflection* getBindingRangeLeafTypeLayout(
SlangInt index)
2907 VariableReflection* getBindingRangeLeafVariable(
SlangInt index)
2988 BindingType getDescriptorSetDescriptorRangeType(
SlangInt setIndex,
SlangInt rangeIndex)
2996 ParameterCategory getDescriptorSetDescriptorRangeCategory(
3015 subObjectRangeIndex);
3027 subObjectRangeIndex);
3030 VariableLayoutReflection* getSubObjectRangeOffset(
SlangInt subObjectRangeIndex)
3034 subObjectRangeIndex);
3056struct VariableReflection
3060 TypeReflection* getType()
3065 Modifier* findModifier(Modifier::ID
id)
3072 unsigned int getUserAttributeCount()
3077 Attribute* getUserAttributeByIndex(
unsigned int index)
3084 Attribute* findAttributeByName(
SlangSession* globalSession,
char const* name)
3092 Attribute* findUserAttributeByName(
SlangSession* globalSession,
char const* name)
3094 return findAttributeByName(globalSession, name);
3097 bool hasDefaultValue()
3112 GenericReflection* getGenericContainer()
3118 VariableReflection* applySpecializations(GenericReflection* generic)
3126struct VariableLayoutReflection
3128 VariableReflection* getVariable()
3134 char const* getName()
3136 if (
auto var = getVariable())
3137 return var->getName();
3141 Modifier* findModifier(Modifier::ID
id) {
return getVariable()->findModifier(
id); }
3143 TypeLayoutReflection* getTypeLayout()
3149 ParameterCategory getCategory() {
return getTypeLayout()->getParameterCategory(); }
3151 unsigned int getCategoryCount() {
return getTypeLayout()->getCategoryCount(); }
3153 ParameterCategory getCategoryByIndex(
unsigned int index)
3155 return getTypeLayout()->getCategoryByIndex(index);
3174 size_t getOffset(slang::ParameterCategory category = slang::ParameterCategory::Uniform)
3182 TypeReflection* getType() {
return getVariable()->getType(); }
3189 unsigned getBindingIndex()
3199 unsigned getBindingSpace()
3219 size_t getBindingSpace(slang::ParameterCategory category)
3231 char const* getSemanticName()
3236 size_t getSemanticIndex()
3247 [[deprecated]] VariableLayoutReflection* getPendingDataLayout() {
return nullptr; }
3250struct FunctionReflection
3254 TypeReflection* getReturnType()
3259 unsigned int getParameterCount()
3264 VariableReflection* getParameterByIndex(
unsigned int index)
3271 unsigned int getUserAttributeCount()
3275 Attribute* getUserAttributeByIndex(
unsigned int index)
3280 Attribute* findAttributeByName(
SlangSession* globalSession,
char const* name)
3287 Attribute* findUserAttributeByName(
SlangSession* globalSession,
char const* name)
3289 return findAttributeByName(globalSession, name);
3291 Modifier* findModifier(Modifier::ID
id)
3298 GenericReflection* getGenericContainer()
3304 FunctionReflection* applySpecializations(GenericReflection* generic)
3311 FunctionReflection* specializeWithArgTypes(
unsigned int argCount, TypeReflection*
const* types)
3324 unsigned int getOverloadCount()
3329 FunctionReflection* getOverload(
unsigned int index)
3337struct GenericReflection
3340 DeclReflection* asDecl()
3347 unsigned int getTypeParameterCount()
3352 VariableReflection* getTypeParameter(
unsigned index)
3359 unsigned int getValueParameterCount()
3364 VariableReflection* getValueParameter(
unsigned index)
3371 unsigned int getTypeParameterConstraintCount(VariableReflection* typeParam)
3378 TypeReflection* getTypeParameterConstraintType(VariableReflection* typeParam,
unsigned index)
3386 DeclReflection* getInnerDecl()
3396 GenericReflection* getOuterGenericContainer()
3402 TypeReflection* getConcreteType(VariableReflection* typeParam)
3409 int64_t getConcreteIntVal(VariableReflection* valueParam)
3416 GenericReflection* applySpecializations(GenericReflection* generic)
3424struct EntryPointReflection
3426 char const* getName()
3431 char const* getNameOverride()
3436 unsigned getParameterCount()
3441 FunctionReflection* getFunction()
3447 VariableLayoutReflection* getParameterByIndex(
unsigned index)
3467 void getComputeWaveSize(
SlangUInt* outWaveSize)
3474 bool usesAnySampleRateInput()
3479 VariableLayoutReflection* getVarLayout()
3485 TypeLayoutReflection* getTypeLayout() {
return getVarLayout()->getTypeLayout(); }
3487 VariableLayoutReflection* getResultVarLayout()
3493 bool hasDefaultConstantBuffer()
3500typedef EntryPointReflection EntryPointLayout;
3502struct TypeParameterReflection
3504 char const* getName()
3512 unsigned getConstraintCount()
3516 TypeReflection* getConstraintByIndex(
int index)
3532typedef struct ShaderReflection ProgramLayout;
3535struct ShaderReflection
3539 unsigned getTypeParameterCount()
3544 slang::ISession* getSession() {
return spReflection_GetSession((
SlangReflection*)
this); }
3546 TypeParameterReflection* getTypeParameterByIndex(
unsigned index)
3553 TypeParameterReflection* findTypeParameter(
char const* name)
3559 VariableLayoutReflection* getParameterByIndex(
unsigned index)
3576 EntryPointReflection* getEntryPointByIndex(
SlangUInt index)
3587 SlangUInt getGlobalConstantBufferBinding()
3598 size_t getGlobalConstantBufferSize()
3603 TypeReflection* findTypeByName(
const char* name)
3608 FunctionReflection* findFunctionByName(
const char* name)
3613 FunctionReflection* findFunctionByNameInType(TypeReflection* type,
const char* name)
3622 uint32_t candidateCount,
3623 FunctionReflection** candidates)
3631 VariableReflection* findVarByNameInType(TypeReflection* type,
const char* name)
3639 TypeLayoutReflection* getTypeLayout(
3640 TypeReflection* type,
3641 LayoutRules rules = LayoutRules::Default)
3649 EntryPointReflection* findEntryPointByName(
const char* name)
3655 TypeReflection* specializeType(
3656 TypeReflection* type,
3658 TypeReflection*
const* specializationArgs,
3664 specializationArgCount,
3669 GenericReflection* specializeGeneric(
3670 GenericReflection* generic,
3672 GenericArgType
const* specializationArgTypes,
3673 GenericArgReflection
const* specializationArgVals,
3679 specializationArgCount,
3685 bool isSubType(TypeReflection* subType, TypeReflection* superType)
3698 const char* getHashedString(
SlangUInt index,
size_t* outCount)
const
3703 TypeLayoutReflection* getGlobalParamsTypeLayout()
3709 VariableLayoutReflection* getGlobalParamsVarLayout()
3730struct DeclReflection
3748 unsigned int getChildrenCount()
3753 DeclReflection* getChild(
unsigned int index)
3758 TypeReflection* getType()
3763 VariableReflection* asVariable()
3768 FunctionReflection* asFunction()
3773 GenericReflection* asGeneric()
3778 DeclReflection* getParent()
3783 Modifier* findModifier(Modifier::ID
id)
3794 DeclReflection* parent;
3796 struct FilteredIterator
3798 DeclReflection* parent;
3802 DeclReflection*
operator*() {
return parent->getChild(index); }
3806 while (index < count && !(parent->getChild(index)->getKind() == K))
3811 bool operator!=(FilteredIterator
const& other) {
return index != other.index; }
3815 FilteredIterator begin()
3818 unsigned int index = 0;
3819 while (index < count && !(parent->getChild(index)->getKind() == K))
3823 return FilteredIterator{parent, count, index};
3826 FilteredIterator end() {
return FilteredIterator{parent, count, count}; }
3830 FilteredList<K> getChildrenOfKind()
3832 return FilteredList<K>{getChildrenCount(), (DeclReflection*)
this};
3838 DeclReflection* parent;
3842 DeclReflection* parent;
3846 DeclReflection*
operator*() {
return parent->getChild(index); }
3847 void operator++() { index++; }
3848 bool operator!=(Iterator
const& other) {
return index != other.index; }
3852 IteratedList::Iterator begin() {
return IteratedList::Iterator{parent, count, 0}; }
3853 IteratedList::Iterator end() {
return IteratedList::Iterator{parent, count, count}; }
3856 IteratedList
getChildren() {
return IteratedList{getChildrenCount(), (DeclReflection*)
this}; }
3859typedef uint32_t CompileCoreModuleFlags;
3860struct CompileCoreModuleFlag
3862 enum Enum : CompileCoreModuleFlags
3864 WriteDocumentation = 0x1,
3870struct IComponentType;
3871struct ITypeConformance;
3872struct IGlobalSession;
3876struct SpecializationArg;
3879enum class BuiltinModuleName
3898 SLANG_COM_INTERFACE(0xc140b5fd, 0xc78, 0x452e, {0xba, 0x7c, 0x1a, 0x1e, 0x70, 0xc7, 0xf7, 0x1c})
3903 createSession(SessionDesc
const& desc, ISession** outSession) = 0;
3922 setDownstreamCompilerPath(
SlangPassThrough passThrough,
char const* path) = 0;
3934 setDownstreamCompilerPrelude(
SlangPassThrough passThrough,
const char* preludeText) = 0;
3997 createCompileRequest(slang::ICompileRequest** outCompileRequest) = 0;
4002 addBuiltins(
char const* sourcePath,
char const* sourceString) = 0;
4042 compileCoreModule(CompileCoreModuleFlags flags) = 0;
4051 loadCoreModule(
const void* coreModule,
size_t coreModuleSizeInBytes) = 0;
4092 getCompilerElapsedTime(
double* outTotalTime,
double* outDownstreamTime) = 0;
4108 const char*
const* argv,
4109 SessionDesc* outSessionDesc,
4115 getSessionDescDigest(SessionDesc* sessionDesc,
ISlangBlob** outBlob) = 0;
4124 compileBuiltinModule(BuiltinModuleName module, CompileCoreModuleFlags flags) = 0;
4134 loadBuiltinModule(BuiltinModuleName module,
const void* moduleData,
size_t sizeInBytes) = 0;
4143 BuiltinModuleName module,
4148 #define SLANG_UUID_IGlobalSession IGlobalSession::getTypeGuid()
4156 size_t structureSize =
sizeof(TargetDesc);
4179 bool forceGLSLScalarBufferLayout =
false;
4183 const CompilerOptionEntry* compilerOptionEntries =
nullptr;
4187 uint32_t compilerOptionEntryCount = 0;
4190typedef uint32_t SessionFlags;
4193 kSessionFlags_None = 0
4196struct PreprocessorMacroDesc
4206 size_t structureSize =
sizeof(SessionDesc);
4210 TargetDesc
const* targets =
nullptr;
4215 SessionFlags flags = kSessionFlags_None;
4223 char const*
const* searchPaths =
nullptr;
4226 PreprocessorMacroDesc
const* preprocessorMacros =
nullptr;
4227 SlangInt preprocessorMacroCount = 0;
4231 bool enableEffectAnnotations =
false;
4232 bool allowGLSLSyntax =
false;
4236 const CompilerOptionEntry* compilerOptionEntries =
nullptr;
4240 uint32_t compilerOptionEntryCount = 0;
4244 bool skipSPIRVValidation =
false;
4247enum class ContainerType
4256struct SourceLocation
4258 const char* filePath =
nullptr;
4290 SLANG_COM_INTERFACE(0x67618701, 0xd116, 0x468f, {0xab, 0x3b, 0x47, 0x4b, 0xed, 0xce, 0xe, 0x3d})
4299 loadModule(
const char* moduleName, IBlob** outDiagnostics =
nullptr) = 0;
4304 const char* moduleName,
4306 slang::IBlob* source,
4307 slang::IBlob** outDiagnostics =
nullptr) = 0;
4339 IComponentType*
const* componentTypes,
4341 IComponentType** outCompositeComponentType,
4347 TypeReflection* type,
4348 SpecializationArg
const* specializationArgs,
4356 TypeReflection* type,
4358 LayoutRules rules = LayoutRules::Default,
4369 TypeReflection* elementType,
4370 ContainerType containerType,
4382 getTypeRTTIMangledName(TypeReflection* type,
ISlangBlob** outNameBlob) = 0;
4387 TypeReflection* type,
4388 TypeReflection* interfaceType,
4395 slang::TypeReflection* type,
4396 slang::TypeReflection* interfaceType,
4397 uint32_t* outId) = 0;
4424 slang::TypeReflection* type,
4425 slang::TypeReflection* interfaceType,
4426 ITypeConformance** outConformance,
4433 const char* moduleName,
4435 slang::IBlob* source,
4436 slang::IBlob** outDiagnostics =
nullptr) = 0;
4445 isBinaryModuleUpToDate(
const char* modulePath, slang::IBlob* binaryModuleBlob) = 0;
4450 const char* moduleName,
4453 slang::IBlob** outDiagnostics =
nullptr) = 0;
4481 slang::TypeReflection* type,
4482 slang::TypeReflection* interfaceType,
4483 uint32_t* outRTTIDataBuffer,
4484 uint32_t bufferSizeInBytes) = 0;
4491 slang::IBlob* source,
4493 const char*& outModuleCompilerVersion,
4494 const char*& outModuleName) = 0;
4501 getDeclSourceLocation(slang::DeclReflection* decl, slang::SourceLocation* outLocation) = 0;
4504 #define SLANG_UUID_ISession ISession::getTypeGuid()
4508 SLANG_COM_INTERFACE(0x8044a8a3, 0xddc0, 0x4b7f, {0xaf, 0x8e, 0x2, 0x6e, 0x90, 0x5d, 0x73, 0x32})
4523 virtual const char*
SLANG_MCALL getDebugBuildIdentifier() = 0;
4525 #define SLANG_UUID_IMetadata IMetadata::getTypeGuid()
4584struct CoverageEntryInfo
4586 size_t structSize =
sizeof(CoverageEntryInfo);
4591 const char*
file =
nullptr;
4613struct CoverageBufferInfo
4615 size_t structSize =
sizeof(CoverageBufferInfo);
4625 int32_t binding = -1;
4634 {0x8e, 0x21, 0x3f, 0x7b, 0x82, 0xa3, 0xd9, 0x51})
4650 getEntryInfo(uint32_t index, CoverageEntryInfo* outInfo) = 0;
4665 #define SLANG_UUID_ICoverageTracingMetadata ICoverageTracingMetadata::getTypeGuid()
4704enum class SyntheticResourceScope : uint32_t
4713enum class SyntheticResourceAccess : uint32_t
4720struct SyntheticResourceInfo
4722 size_t structSize =
sizeof(SyntheticResourceInfo);
4735 BindingType bindingType = BindingType::Unknown;
4739 uint32_t arraySize = 1;
4745 SyntheticResourceScope scope = SyntheticResourceScope::Global;
4748 SyntheticResourceAccess access = SyntheticResourceAccess::Read;
4752 int32_t entryPointIndex = -1;
4771 int32_t binding = -1;
4775 int32_t uniformOffset = -1;
4779 int32_t uniformStride = 0;
4784 const char* debugName =
nullptr;
4793 {0xb8, 0x9e, 0x21, 0x54, 0x95, 0xbb, 0x38, 0x8b})
4807 getResourceInfo(uint32_t index, SyntheticResourceInfo* outInfo) = 0;
4814 findResourceIndexByID(uint32_t
id, uint32_t* outIndex) = 0;
4816 #define SLANG_UUID_ISyntheticResourceMetadata ISyntheticResourceMetadata::getTypeGuid()
4818struct CooperativeMatrixType
4824 uint32_t rowCount = 0;
4825 uint32_t columnCount = 0;
4830struct CooperativeMatrixCombination
4848struct CooperativeVectorTypeUsageInfo
4854 uint32_t maxSize = 0;
4862struct CooperativeVectorCombination
4868 uint32_t inputPackingFactor = 1;
4901 {0x9f, 0xde, 0x3f, 0x0f, 0x9c, 0x6f, 0x01, 0x31})
4905 getCooperativeMatrixTypeByIndex(
SlangUInt index, CooperativeMatrixType* outType) = 0;
4910 CooperativeMatrixCombination* outCombination) = 0;
4914 getCooperativeVectorTypeByIndex(
SlangUInt index, CooperativeVectorTypeUsageInfo* outType) = 0;
4919 CooperativeVectorCombination* outCombination) = 0;
4921 #define SLANG_UUID_ICooperativeTypesMetadata ICooperativeTypesMetadata::getTypeGuid()
4933 {0x9f, 0x12, 0x4b, 0xad, 0x4d, 0x9e, 0xaa, 0xe4})
4939 #define SLANG_UUID_ICompileResult ICompileResult::getTypeGuid()
5004 SLANG_COM_INTERFACE(0x5bc42be8, 0x5c50, 0x4929, {0x9e, 0x5e, 0xd1, 0x5e, 0x7c, 0x24, 0x1, 0x5f})
5034 getLayout(
SlangInt targetIndex = 0, IBlob** outDiagnostics =
nullptr) = 0;
5066 IBlob** outDiagnostics =
nullptr) = 0;
5088 getEntryPointHash(
SlangInt entryPointIndex,
SlangInt targetIndex, IBlob** outHash) = 0;
5098 SpecializationArg
const* specializationArgs,
5100 IComponentType** outSpecializedComponentType,
5122 link(IComponentType** outLinkedComponentType,
ISlangBlob** outDiagnostics =
nullptr) = 0;
5137 int entryPointIndex,
5140 slang::IBlob** outDiagnostics = 0) = 0;
5148 renameEntryPoint(
const char* newName, IComponentType** outEntryPoint) = 0;
5154 IComponentType** outLinkedComponentType,
5155 uint32_t compilerOptionEntryCount,
5156 CompilerOptionEntry
const* compilerOptionEntries,
5165 getTargetCode(
SlangInt targetIndex, IBlob** outCode, IBlob** outDiagnostics =
nullptr) = 0;
5174 IMetadata** outMetadata,
5175 IBlob** outDiagnostics =
nullptr) = 0;
5186 IMetadata** outMetadata,
5187 IBlob** outDiagnostics =
nullptr) = 0;
5189 #define SLANG_UUID_IComponentType IComponentType::getTypeGuid()
5191struct IEntryPoint :
public IComponentType
5193 SLANG_COM_INTERFACE(0x8f241361, 0xf5bd, 0x4ca0, {0xa3, 0xac, 0x2, 0xf7, 0xfa, 0x24, 0x2, 0xb8})
5198 #define SLANG_UUID_IEntryPoint IEntryPoint::getTypeGuid()
5200struct ITypeConformance :
public IComponentType
5202 SLANG_COM_INTERFACE(0x73eb3147, 0xe544, 0x41b5, {0xb8, 0xf0, 0xa2, 0x44, 0xdf, 0x21, 0x94, 0xb})
5204 #define SLANG_UUID_ITypeConformance ITypeConformance::getTypeGuid()
5221 {0xa5, 0x2c, 0x8b, 0x19, 0x3e, 0x45, 0x7a, 0x9f})
5225 ICompileResult** outCompileResult,
5226 IBlob** outDiagnostics =
nullptr) = 0;
5230 ICompileResult** outCompileResult,
5231 IBlob** outDiagnostics =
nullptr) = 0;
5246 slang::IBlob** outDiagnostics = 0) = 0;
5248 #define SLANG_UUID_IComponentType2 IComponentType2::getTypeGuid()
5263struct IModule :
public IComponentType
5265 SLANG_COM_INTERFACE(0xc720e64, 0x8722, 0x4d31, {0x89, 0x90, 0x63, 0x8a, 0x98, 0xb1, 0xc2, 0x79})
5272 findEntryPointByName(
char const* name, IEntryPoint** outEntryPoint) = 0;
5281 getDefinedEntryPoint(
SlangInt32 index, IEntryPoint** outEntryPoint) = 0;
5303 IEntryPoint** outEntryPoint,
5320 disassemble(slang::IBlob** outDisassembledBlob) = 0;
5323 #define SLANG_UUID_IModule IModule::getTypeGuid()
5326struct IModulePrecompileService_Experimental :
public ISlangUnknown
5333 {0xaf, 0xcb, 0x13, 0xa0, 0x88, 0xbc, 0x5e, 0xe5})
5341 IBlob** outDiagnostics =
nullptr) = 0;
5347 IModule** outModule,
5348 IBlob** outDiagnostics =
nullptr) = 0;
5351 #define SLANG_UUID_IModulePrecompileService_Experimental \
5352 IModulePrecompileService_Experimental::getTypeGuid()
5356struct SpecializationArg
5358 enum class Kind : int32_t
5370 TypeReflection* type;
5375 static SpecializationArg fromType(TypeReflection* inType)
5377 SpecializationArg rs;
5378 rs.kind = Kind::Type;
5383 static SpecializationArg fromExpr(
const char* inExpr)
5385 SpecializationArg rs;
5386 rs.kind = Kind::Expr;
5395 #define SLANG_API_VERSION 0
5397enum SlangLanguageVersion
5399 SLANG_LANGUAGE_VERSION_UNKNOWN = 0,
5400 SLANG_LANGUAGE_VERSION_LEGACY = 2018,
5401 SLANG_LANGUAGE_VERSION_2025 = 2025,
5402 SLANG_LANGUAGE_VERSION_2026 = 2026,
5404 SLANG_LANGAUGE_VERSION_DEFAULT = SLANG_LANGUAGE_VERSION_LEGACY,
5405 SLANG_LANGUAGE_VERSION_DEFAULT = SLANG_LANGUAGE_VERSION_LEGACY,
5406 SLANG_LANGUAGE_VERSION_LATEST = SLANG_LANGUAGE_VERSION_2026,
5412struct SlangGlobalSessionDesc
5415 uint32_t structureSize =
sizeof(SlangGlobalSessionDesc);
5418 uint32_t apiVersion = SLANG_API_VERSION;
5421 uint32_t minLanguageVersion = SLANG_LANGUAGE_VERSION_2025;
5424 bool enableGLSL =
false;
5427 uint32_t reserved[16] = {};
5458slang_writeCoverageManifestJson(slang::ICoverageTracingMetadata* metadata,
ISlangBlob** outBlob);
5471 slang::ISession* session,
5472 const char* moduleName,
5488 slang::ISession* session,
5489 const char* moduleName,
5505 slang::ISession* session,
5509 const char*& outModuleCompilerVersion,
5510 const char*& outModuleName);
5518slang_createGlobalSession(
SlangInt apiVersion, slang::IGlobalSession** outGlobalSession);
5527 const SlangGlobalSessionDesc* desc,
5528 slang::IGlobalSession** outGlobalSession);
5540 slang::IGlobalSession** outGlobalSession);
5616enum class OperandDataType
5635 void* getPtr()
const {
return *section + offset; }
5636 OperandDataType getType()
const {
return (OperandDataType)type; }
5639struct VMExecInstHeader;
5640class IByteCodeRunner;
5642typedef void (*VMExtFunction)(IByteCodeRunner* context, VMExecInstHeader* inst,
void* userData);
5643typedef void (*VMPrintFunc)(
const char* message,
void* userData);
5645struct VMExecInstHeader
5647 VMExtFunction functionPtr;
5651 uint32_t opcodeExtension;
5652 uint32_t operandCount;
5653 VMExecInstHeader* getNextInst()
5655 return (VMExecInstHeader*)((VMExecOperand*)(
this + 1) + operandCount);
5657 VMExecOperand& getOperand(
SlangInt index)
const
5659 return *((VMExecOperand*)(
this + 1) + index);
5663struct ByteCodeFuncInfo
5665 uint32_t parameterCount;
5666 uint32_t returnValueSize;
5669struct ByteCodeRunnerDesc
5673 size_t structSize =
sizeof(ByteCodeRunnerDesc);
5681 SLANG_COM_INTERFACE(0xafdab195, 0x361f, 0x42cb, {0x95, 0x13, 0x90, 0x6, 0x26, 0x1d, 0xd8, 0xcd})
5688 selectFunctionByIndex(uint32_t functionIndex) = 0;
5693 getFunctionInfo(uint32_t index, ByteCodeFuncInfo* outInfo) = 0;
5700 execute(
void* argumentData,
size_t argumentSize) = 0;
5713 registerExtCall(
const char* name, VMExtFunction functionPtr) = 0;
5717 setPrintCallback(VMPrintFunc callback,
void* userData) = 0;
5724 const slang::ByteCodeRunnerDesc* desc,
5725 slang::IByteCodeRunner** outByteCodeRunner);
5729slang_disassembleByteCode(slang::IBlob* moduleBlob, slang::IBlob** outDisassemblyBlob);
5733inline SlangResult createGlobalSession(slang::IGlobalSession** outGlobalSession)
5735 SlangGlobalSessionDesc defaultDesc = {};
5736 return slang_createGlobalSession2(&defaultDesc, outGlobalSession);
5739 const SlangGlobalSessionDesc* desc,
5740 slang::IGlobalSession** outGlobalSession)
5742 return slang_createGlobalSession2(desc, outGlobalSession);
5744inline void shutdown()
5748inline const char* getLastInternalErrorMessage()
5750 return slang_getLastInternalErrorMessage();
5756#define SLANG_ERROR_INSUFFICIENT_BUFFER SLANG_E_BUFFER_TOO_SMALL
5757#define SLANG_ERROR_INVALID_PARAMETER SLANG_E_INVALID_ARG
static std::vector< YGNodeRef > getChildren(YGNodeRef const node)
Definition YGTreeMutationTest.cpp:11
SLANG_COM_INTERFACE(0x87ede0e1, 0x4852, 0x44b0, {0x8b, 0xf2, 0xcb, 0x31, 0x87, 0x4d, 0xe2, 0x39})
virtual SLANG_NO_THROW void *SLANG_MCALL castAs(const SlangUUID &guid)=0
virtual SLANG_NO_THROW void *SLANG_MCALL clone(const SlangUUID &guid)=0
SLANG_COM_INTERFACE(0x1ec36168, 0xe9f4, 0x430d, {0xbb, 0x17, 0x4, 0x8a, 0x80, 0x46, 0xb3, 0x1f})
bool operator!=(const json_pointer< RefStringTypeLhs > &lhs, const json_pointer< RefStringTypeRhs > &rhs) noexcept
Definition json.hpp:14762
@ value
the parser finished reading a JSON value
auto get(const nlohmann::detail::iteration_proxy_value< IteratorType > &i) -> decltype(i.key())
Definition json.hpp:5342
uint8_t Type
Definition slang-gfx.h:1359
file
Definition set-version.py:14
CompilerOptionName
Definition slang.h:965
@ ParameterBlocksUseRegisterSpaces
@ NoHLSLPackConstantBufferElements
@ DisableNonEssentialValidations
@ TraceCoverageReservedSpace
@ RestrictiveCapabilityCheck
@ MinimumSlangOptimization
@ SPIRVResourceHeapStride
@ SaveGLSLModuleBinSource
@ ReportCheckpointIntermediates
@ ReportDynamicDispatchSites
@ SaveCoreModuleBinSource
@ EnableExperimentalDynamicDispatch
@ DefaultDownstreamCompiler
@ VulkanUseEntryPointName
@ GetSupportedModuleVersions
@ DefaultImageFormatUnknown
@ EnableEffectAnnotations
@ UseUpToDateBinaryModule
@ EnableExperimentalPasses
@ ReportDetailedPerfBenchmark
@ UseMSVCStyleBitfieldPacking
@ EnableMachineReadableDiagnostics
CompilerOptionValueKind
Definition slang.h:1182
int32_t SlangResult
Definition slang-cpp-prelude.h:300
#define SLANG_NO_THROW
Definition slang-cpp-prelude.h:268
#define SLANG_MCALL
Definition slang-cpp-prelude.h:282
#define SLANG_COM_INTERFACE(a, b, c, d0, d1, d2, d3, d4, d5, d6, d7)
Definition slang-cpp-prelude.h:310
__inline__ __device__ uint3 operator*(uint3 a, dim3 b)
Definition slang-cuda-prelude.h:4314
SLANG_API char const * spReflectionDecl_getName(SlangReflectionDecl *decl)
SLANG_API SlangReflectionTypeLayout * spReflectionTypeLayout_GetElementTypeLayout(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionEntryPoint * spReflection_findEntryPointByName(SlangReflection *reflection, char const *name)
SLANG_API SlangResult spReflectionVariable_GetDefaultValueFloat(SlangReflectionVariable *inVar, float *rs)
SLANG_API SlangInt spReflectionTypeLayout_getDescriptorSetSpaceOffset(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex)
SLANG_API int spReflectionEntryPoint_hasDefaultConstantBuffer(SlangReflectionEntryPoint *entryPoint)
SLANG_API size_t spReflectionVariableLayout_GetSemanticIndex(SlangReflectionVariableLayout *var)
SLANG_API unsigned spReflectionTypeParameter_GetConstraintCount(SlangReflectionTypeParameter *typeParam)
SLANG_API SlangInt spReflectionTypeLayout_getSubObjectRangeSpaceOffset(SlangReflectionTypeLayout *typeLayout, SlangInt subObjectRangeIndex)
SLANG_API char const * spReflectionEntryPoint_getName(SlangReflectionEntryPoint *entryPoint)
SLANG_API int32_t spReflectionTypeLayout_getAlignment(SlangReflectionTypeLayout *type, SlangParameterCategory category)
SLANG_API SlangUInt spReflection_getHashedStringCount(SlangReflection *reflection)
Get the number of hashed strings
SLANG_API size_t spReflectionTypeLayout_GetElementStride(SlangReflectionTypeLayout *type, SlangParameterCategory category)
SLANG_API SlangReflectionType * spReflectionVariable_GetType(SlangReflectionVariable *var)
SLANG_API SlangReflectionVariable * spReflectionGeneric_GetValueParameter(SlangReflectionGeneric *generic, unsigned index)
SLANG_API SlangBindingType spReflectionTypeLayout_getBindingRangeType(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API SlangUInt spReflection_getGlobalConstantBufferBinding(SlangReflection *reflection)
SLANG_API unsigned int spReflectionUserAttribute_GetArgumentCount(SlangReflectionUserAttribute *attrib)
SLANG_API unsigned int spReflectionGeneric_GetValueParameterCount(SlangReflectionGeneric *generic)
SLANG_API SlangInt spReflection_getBindlessSpaceIndex(SlangReflection *reflection)
SLANG_API SlangScalarType spReflectionType_GetScalarType(SlangReflectionType *type)
SLANG_API SlangStage spReflectionEntryPoint_getStage(SlangReflectionEntryPoint *entryPoint)
SLANG_API SlangReflectionVariable * spReflectionVariable_applySpecializations(SlangReflectionVariable *var, SlangReflectionGeneric *generic)
SLANG_API SlangTypeKind spReflectionType_GetKind(SlangReflectionType *type)
SLANG_API SlangImageFormat spReflectionTypeLayout_getBindingRangeImageFormat(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API SlangResult spReflectionVariable_GetDefaultValueInt(SlangReflectionVariable *inVar, int64_t *rs)
SLANG_API SlangParameterCategory spReflectionTypeLayout_getDescriptorSetDescriptorRangeCategory(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex, SlangInt rangeIndex)
SLANG_API int64_t spReflectionGeneric_GetConcreteIntVal(SlangReflectionGeneric *generic, SlangReflectionVariable *valueParam)
SLANG_API unsigned int spReflectionType_GetFieldCount(SlangReflectionType *type)
SLANG_API unsigned spReflectionEntryPoint_getParameterCount(SlangReflectionEntryPoint *entryPoint)
SLANG_API size_t spReflectionTypeLayout_GetSize(SlangReflectionTypeLayout *type, SlangParameterCategory category)
SLANG_API SlangReflectionType * spReflectionType_GetElementType(SlangReflectionType *type)
SLANG_API SlangReflectionUserAttribute * spReflectionType_GetUserAttribute(SlangReflectionType *type, unsigned int index)
SLANG_API SlangInt spReflectionTypeLayout_getDescriptorSetCount(SlangReflectionTypeLayout *typeLayout)
SLANG_API const char * spReflection_getHashedString(SlangReflection *reflection, SlangUInt index, size_t *outCount)
SLANG_API SlangReflectionUserAttribute * spReflectionType_FindUserAttributeByName(SlangReflectionType *type, char const *name)
SLANG_API SlangReflectionType * spReflectionGeneric_GetTypeParameterConstraintType(SlangReflectionGeneric *generic, SlangReflectionVariable *typeParam, unsigned index)
SLANG_API SlangReflectionType * spReflectionTypeLayout_GetType(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionGeneric * spReflectionGeneric_applySpecializations(SlangReflectionGeneric *currGeneric, SlangReflectionGeneric *generic)
SLANG_API SlangResourceAccess spReflectionType_GetResourceAccess(SlangReflectionType *type)
SLANG_API unsigned int spReflection_GetTypeParameterCount(SlangReflection *reflection)
SLANG_API SlangUInt spReflection_getEntryPointCount(SlangReflection *reflection)
SLANG_API SlangReflectionGeneric * spReflectionType_GetGenericContainer(SlangReflectionType *type)
SLANG_API char const * spReflectionGeneric_GetName(SlangReflectionGeneric *generic)
SLANG_API void spReflectionEntryPoint_getComputeWaveSize(SlangReflectionEntryPoint *entryPoint, SlangUInt *outWaveSize)
SLANG_API unsigned int spReflectionGeneric_GetTypeParameterConstraintCount(SlangReflectionGeneric *generic, SlangReflectionVariable *typeParam)
SLANG_API SlangReflectionFunction * spReflectionEntryPoint_getFunction(SlangReflectionEntryPoint *entryPoint)
SLANG_API SlangReflectionTypeParameter * spReflection_GetTypeParameterByIndex(SlangReflection *reflection, unsigned int index)
SLANG_API char const * spReflectionType_GetName(SlangReflectionType *type)
SLANG_API SlangInt spReflectionTypeLayout_getBindingRangeDescriptorRangeCount(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API SlangReflectionGeneric * spReflectionFunction_GetGenericContainer(SlangReflectionFunction *func)
SLANG_API SlangReflectionParameter * spReflection_GetParameterByIndex(SlangReflection *reflection, unsigned index)
SLANG_API unsigned int spReflectionType_GetRowCount(SlangReflectionType *type)
SLANG_API size_t spReflectionType_GetSpecializedElementCount(SlangReflectionType *type, SlangReflection *reflection)
SLANG_API SlangReflectionModifier * spReflectionFunction_FindModifier(SlangReflectionFunction *var, SlangModifierID modifierID)
SLANG_API unsigned int spReflectionFunction_GetParameterCount(SlangReflectionFunction *func)
SLANG_API SlangInt spReflectionTypeLayout_getBindingRangeFirstDescriptorRangeIndex(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API char const * spReflectionUserAttribute_GetName(SlangReflectionUserAttribute *attrib)
SLANG_API SlangReflectionType * spReflectionType_GetResourceResultType(SlangReflectionType *type)
SLANG_API SlangReflectionVariable * spReflectionTypeLayout_getBindingRangeLeafVariable(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API unsigned spReflection_GetParameterCount(SlangReflection *reflection)
SLANG_API SlangReflectionFunction * spReflection_FindFunctionByNameInType(SlangReflection *reflection, SlangReflectionType *reflType, char const *name)
SLANG_API SlangBindingType spReflectionTypeLayout_getDescriptorSetDescriptorRangeType(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex, SlangInt rangeIndex)
SLANG_API size_t spReflection_getGlobalConstantBufferSize(SlangReflection *reflection)
SLANG_API SlangReflectionUserAttribute * spReflectionFunction_GetUserAttribute(SlangReflectionFunction *func, unsigned int index)
SLANG_API SlangInt spReflectionTypeLayout_getBindingRangeBindingCount(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API size_t spReflectionVariableLayout_GetOffset(SlangReflectionVariableLayout *var, SlangParameterCategory category)
SLANG_API SlangResult spReflectionUserAttribute_GetArgumentValueFloat(SlangReflectionUserAttribute *attrib, unsigned int index, float *rs)
SLANG_API SlangReflectionTypeLayout * spReflectionVariableLayout_GetTypeLayout(SlangReflectionVariableLayout *var)
SLANG_API SlangReflectionVariable * spReflectionDecl_castToVariable(SlangReflectionDecl *decl)
SLANG_API SlangReflectionFunction * spReflectionDecl_castToFunction(SlangReflectionDecl *decl)
SLANG_API SlangDeclKind spReflectionGeneric_GetInnerKind(SlangReflectionGeneric *generic)
SLANG_API SlangReflectionType * spReflectionUserAttribute_GetArgumentType(SlangReflectionUserAttribute *attrib, unsigned int index)
SLANG_API SlangReflectionUserAttribute * spReflectionVariable_GetUserAttribute(SlangReflectionVariable *var, unsigned int index)
SLANG_API SlangReflectionType * spReflection_specializeType(SlangReflection *reflection, SlangReflectionType *type, SlangInt specializationArgCount, SlangReflectionType *const *specializationArgs, ISlangBlob **outDiagnostics)
SLANG_API SlangInt spReflectionTypeLayout_getBindingRangeDescriptorSetIndex(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API unsigned int spReflectionType_GetUserAttributeCount(SlangReflectionType *type)
SLANG_API unsigned int spReflectionGeneric_GetTypeParameterCount(SlangReflectionGeneric *generic)
SLANG_API SlangReflectionType * spReflectionFunction_GetResultType(SlangReflectionFunction *func)
SLANG_API SlangReflectionGeneric * spReflectionVariable_GetGenericContainer(SlangReflectionVariable *var)
SLANG_API int spReflectionTypeLayout_getGenericParamIndex(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionType * spReflectionType_applySpecializations(SlangReflectionType *type, SlangReflectionGeneric *generic)
SLANG_API SlangReflectionFunction * spReflectionFunction_getOverload(SlangReflectionFunction *func, unsigned int index)
SLANG_API SlangMatrixLayoutMode spReflectionTypeLayout_GetMatrixLayoutMode(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionDecl * spReflectionGeneric_asDecl(SlangReflectionGeneric *generic)
SLANG_API SlangReflectionVariableLayout * spReflectionTypeLayout_GetFieldByIndex(SlangReflectionTypeLayout *type, unsigned index)
SLANG_API SlangReflectionVariable * spReflection_FindVarByNameInType(SlangReflection *reflection, SlangReflectionType *reflType, char const *name)
SLANG_API SlangReflectionTypeLayout * spReflectionTypeLayout_getBindingRangeLeafTypeLayout(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API int spReflectionEntryPoint_usesAnySampleRateInput(SlangReflectionEntryPoint *entryPoint)
SLANG_API unsigned int spReflectionDecl_getChildrenCount(SlangReflectionDecl *parentDecl)
SLANG_API SlangInt spReflectionTypeLayout_getSubObjectRangeCount(SlangReflectionTypeLayout *typeLayout)
SLANG_API SlangReflectionVariable * spReflectionGeneric_GetTypeParameter(SlangReflectionGeneric *generic, unsigned index)
SLANG_API SlangReflectionVariableLayout * spReflectionEntryPoint_getResultVarLayout(SlangReflectionEntryPoint *entryPoint)
SLANG_API char const * spReflectionEntryPoint_getNameOverride(SlangReflectionEntryPoint *entryPoint)
SLANG_API SlangReflectionVariableLayout * spReflectionTypeLayout_getContainerVarLayout(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionVariableLayout * spReflectionEntryPoint_getVarLayout(SlangReflectionEntryPoint *entryPoint)
SLANG_API char const * spReflectionVariable_GetName(SlangReflectionVariable *var)
SLANG_API bool spReflectionFunction_isOverloaded(SlangReflectionFunction *func)
SLANG_API SlangReflectionEntryPoint * spReflection_getEntryPointByIndex(SlangReflection *reflection, SlangUInt index)
SLANG_API SlangInt spReflectionTypeLayout_getExplicitCounterBindingRangeOffset(SlangReflectionTypeLayout *inTypeLayout)
SLANG_API SlangReflectionFunction * spReflectionFunction_applySpecializations(SlangReflectionFunction *func, SlangReflectionGeneric *generic)
SLANG_API SlangReflectionGeneric * spReflectionDecl_castToGeneric(SlangReflectionDecl *decl)
SLANG_API const char * spReflectionUserAttribute_GetArgumentValueString(SlangReflectionUserAttribute *attrib, unsigned int index, size_t *outSize)
SLANG_API SlangReflectionTypeLayout * spReflection_getGlobalParamsTypeLayout(SlangReflection *reflection)
Get a type layout representing reflection information for the global-scope parameters.
SLANG_API SlangReflectionType * spReflection_getTypeFromDecl(SlangReflectionDecl *decl)
SLANG_API unsigned int spReflectionFunction_getOverloadCount(SlangReflectionFunction *func)
SLANG_API SlangInt spReflectionTypeLayout_getSubObjectRangeBindingRangeIndex(SlangReflectionTypeLayout *typeLayout, SlangInt subObjectRangeIndex)
SLANG_API unsigned int spReflectionType_GetColumnCount(SlangReflectionType *type)
SLANG_API SlangReflectionDecl * spReflectionDecl_getParent(SlangReflectionDecl *decl)
SLANG_API SlangInt spReflectionTypeLayout_getBindingRangeCount(SlangReflectionTypeLayout *typeLayout)
SLANG_API SlangResourceShape spReflectionType_GetResourceShape(SlangReflectionType *type)
SLANG_API char const * spReflectionVariableLayout_GetSemanticName(SlangReflectionVariableLayout *var)
SLANG_API SlangReflectionDecl * spReflectionGeneric_GetInnerDecl(SlangReflectionGeneric *generic)
SLANG_API SlangReflectionModifier * spReflectionVariable_FindModifier(SlangReflectionVariable *var, SlangModifierID modifierID)
SLANG_API SlangReflectionFunction * spReflectionFunction_specializeWithArgTypes(SlangReflectionFunction *func, SlangInt argTypeCount, SlangReflectionType *const *argTypes)
SLANG_API SlangReflectionGeneric * spReflectionGeneric_GetOuterGenericContainer(SlangReflectionGeneric *generic)
SLANG_API void spReflectionEntryPoint_getComputeThreadGroupSize(SlangReflectionEntryPoint *entryPoint, SlangUInt axisCount, SlangUInt *outSizeAlongAxis)
SLANG_API SlangReflection * spGetReflection(SlangCompileRequest *request)
SLANG_API char const * spReflectionFunction_GetName(SlangReflectionFunction *func)
SLANG_API SlangInt spReflectionTypeLayout_getFieldBindingRangeOffset(SlangReflectionTypeLayout *typeLayout, SlangInt fieldIndex)
SLANG_API SlangReflectionVariableLayout * spReflectionTypeLayout_GetExplicitCounter(SlangReflectionTypeLayout *typeLayout)
SLANG_API SlangReflectionVariable * spReflectionType_GetFieldByIndex(SlangReflectionType *type, unsigned index)
SLANG_API SlangParameterCategory spReflectionTypeLayout_GetCategoryByIndex(SlangReflectionTypeLayout *type, unsigned index)
SLANG_API SlangReflectionDecl * spReflectionDecl_getChild(SlangReflectionDecl *parentDecl, unsigned int index)
SLANG_API unsigned spReflectionTypeParameter_GetIndex(SlangReflectionTypeParameter *typeParam)
SLANG_API SlangInt spReflectionTypeLayout_getDescriptorSetDescriptorRangeDescriptorCount(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex, SlangInt rangeIndex)
SLANG_API unsigned spReflectionTypeLayout_GetCategoryCount(SlangReflectionTypeLayout *type)
SLANG_API SlangReflectionVariableLayout * spReflection_getGlobalParamsVarLayout(SlangReflection *reflection)
Get a variable layout representing reflection information for the global-scope parameters.
SLANG_API size_t spReflectionVariableLayout_GetSpace(SlangReflectionVariableLayout *var, SlangParameterCategory category)
SLANG_API SlangReflectionGeneric * spReflection_specializeGeneric(SlangReflection *inProgramLayout, SlangReflectionGeneric *generic, SlangInt argCount, SlangReflectionGenericArgType const *argTypes, SlangReflectionGenericArg const *args, ISlangBlob **outDiagnostics)
SLANG_API SlangReflectionType * spReflectionGeneric_GetConcreteType(SlangReflectionGeneric *generic, SlangReflectionVariable *typeParam)
SLANG_API unsigned spReflectionParameter_GetBindingIndex(SlangReflectionParameter *parameter)
SLANG_API SlangReflectionVariableLayout * spReflectionTypeLayout_getSubObjectRangeOffset(SlangReflectionTypeLayout *typeLayout, SlangInt subObjectRangeIndex)
SLANG_API SlangDeclKind spReflectionDecl_getKind(SlangReflectionDecl *decl)
SLANG_API SlangReflectionModifier * spReflectionDecl_findModifier(SlangReflectionDecl *decl, SlangModifierID modifierID)
SLANG_API SlangResult spReflectionUserAttribute_GetArgumentValueInt(SlangReflectionUserAttribute *attrib, unsigned int index, int *rs)
SLANG_API SlangReflectionFunction * spReflection_FindFunctionByName(SlangReflection *reflection, char const *name)
SLANG_API SlangStage spReflectionVariableLayout_getStage(SlangReflectionVariableLayout *var)
SLANG_API SlangParameterCategory spReflectionTypeLayout_GetParameterCategory(SlangReflectionTypeLayout *type)
SLANG_API uint32_t spReflectionTypeLayout_GetFieldCount(SlangReflectionTypeLayout *type)
SLANG_API SlangTypeKind spReflectionTypeLayout_getKind(SlangReflectionTypeLayout *type)
SLANG_API SlangResult spReflection_ToJson(SlangReflection *reflection, SlangCompileRequest *request, ISlangBlob **outBlob)
SLANG_API SlangReflectionVariable * spReflectionVariableLayout_GetVariable(SlangReflectionVariableLayout *var)
SLANG_API SlangReflectionType * spReflectionTypeParameter_GetConstraintByIndex(SlangReflectionTypeParameter *typeParam, unsigned int index)
SLANG_API SlangReflectionVariableLayout * spReflectionEntryPoint_getParameterByIndex(SlangReflectionEntryPoint *entryPoint, unsigned index)
SLANG_API SlangReflectionType * spReflection_FindTypeByName(SlangReflection *reflection, char const *name)
SLANG_API char const * spReflectionTypeParameter_GetName(SlangReflectionTypeParameter *typeParam)
SLANG_API SlangResult spReflectionType_GetFullName(SlangReflectionType *type, ISlangBlob **outNameBlob)
SLANG_API unsigned int spReflectionFunction_GetUserAttributeCount(SlangReflectionFunction *func)
SLANG_API size_t spReflectionTypeLayout_GetStride(SlangReflectionTypeLayout *type, SlangParameterCategory category)
SLANG_API bool spReflectionVariable_HasDefaultValue(SlangReflectionVariable *inVar)
SLANG_API SlangReflectionVariableLayout * spReflectionTypeLayout_GetElementVarLayout(SlangReflectionTypeLayout *type)
SLANG_API SlangInt spReflectionTypeLayout_isBindingRangeSpecializable(SlangReflectionTypeLayout *typeLayout, SlangInt index)
SLANG_API unsigned spReflectionParameter_GetBindingSpace(SlangReflectionParameter *parameter)
SLANG_API SlangInt spReflectionTypeLayout_findFieldIndexByName(SlangReflectionTypeLayout *typeLayout, const char *nameBegin, const char *nameEnd)
SLANG_API SlangReflectionTypeLayout * spReflection_GetTypeLayout(SlangReflection *reflection, SlangReflectionType *reflectionType, SlangLayoutRules rules)
SLANG_API SlangReflectionUserAttribute * spReflectionFunction_FindUserAttributeByName(SlangReflectionFunction *func, SlangSession *globalSession, char const *name)
SLANG_API SlangReflectionUserAttribute * spReflectionVariable_FindUserAttributeByName(SlangReflectionVariable *var, SlangSession *globalSession, char const *name)
SLANG_API SlangReflectionVariable * spReflectionFunction_GetParameter(SlangReflectionFunction *func, unsigned index)
SLANG_API SlangReflectionTypeParameter * spReflection_FindTypeParameter(SlangReflection *reflection, char const *name)
SLANG_API SlangInt spReflectionTypeLayout_getDescriptorSetDescriptorRangeIndexOffset(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex, SlangInt rangeIndex)
SLANG_API bool spReflection_isSubType(SlangReflection *reflection, SlangReflectionType *subType, SlangReflectionType *superType)
SLANG_API SlangReflectionFunction * spReflection_TryResolveOverloadedFunction(SlangReflection *reflection, uint32_t candidateCount, SlangReflectionFunction **candidates)
SLANG_API SlangInt spReflectionTypeLayout_getDescriptorSetDescriptorRangeCount(SlangReflectionTypeLayout *typeLayout, SlangInt setIndex)
SLANG_API SlangImageFormat spReflectionVariableLayout_GetImageFormat(SlangReflectionVariableLayout *var)
SLANG_API unsigned int spReflectionVariable_GetUserAttributeCount(SlangReflectionVariable *var)
unsigned int SlangFloatingPointModeIntegral
Options to control floating-point precision guarantees for a target.
Definition slang.h:762
unsigned int SlangLineDirectiveModeIntegral
Options to control emission of #line directives
Definition slang.h:784
#define SLANG_UNBOUNDED_SIZE
Definition slang.h:2282
struct SlangReflectionGeneric SlangReflectionGeneric
Definition slang.h:1951
SlangSeverity
Definition slang.h:577
@ SLANG_SEVERITY_DISABLED
Definition slang.h:578
@ SLANG_SEVERITY_FATAL
Definition slang.h:582
@ SLANG_SEVERITY_INTERNAL
Definition slang.h:583
@ SLANG_SEVERITY_ERROR
Definition slang.h:581
@ SLANG_SEVERITY_NOTE
Definition slang.h:579
@ SLANG_SEVERITY_WARNING
Definition slang.h:580
unsigned int SlangProfileIDIntegral
Definition slang.h:814
int32_t SlangInt
Definition slang.h:559
SlangEmitCPUMethod
Definition slang.h:936
@ SLANG_EMIT_CPU_VIA_CPP
Definition slang.h:938
@ SLANG_EMIT_CPU_DEFAULT
Definition slang.h:937
@ SLANG_EMIT_CPU_VIA_LLVM
Definition slang.h:939
bool SlangBool
Definition slang.h:566
struct SlangReflectionModifier SlangReflectionModifier
Definition slang.h:1942
int SlangDiagnosticFlags
Definition slang.h:588
SlangResourceShape
Definition slang.h:2044
@ SLANG_TEXTURE_SUBPASS_MULTISAMPLE
Definition slang.h:2076
@ SLANG_RESOURCE_BASE_SHAPE_MASK
Definition slang.h:2045
@ SLANG_ACCELERATION_STRUCTURE
Definition slang.h:2058
@ SLANG_TEXTURE_CUBE_ARRAY
Definition slang.h:2071
@ SLANG_TEXTURE_2D
Definition slang.h:2050
@ SLANG_TEXTURE_BUFFER
Definition slang.h:2053
@ SLANG_TEXTURE_COMBINED_FLAG
Definition slang.h:2067
@ SLANG_TEXTURE_FEEDBACK_FLAG
Definition slang.h:2063
@ SLANG_TEXTURE_2D_MULTISAMPLE
Definition slang.h:2073
@ SLANG_RESOURCE_UNKNOWN
Definition slang.h:2057
@ SLANG_STRUCTURED_BUFFER
Definition slang.h:2055
@ SLANG_RESOURCE_EXT_SHAPE_MASK
Definition slang.h:2061
@ SLANG_TEXTURE_1D_ARRAY
Definition slang.h:2069
@ SLANG_TEXTURE_1D
Definition slang.h:2049
@ SLANG_RESOURCE_NONE
Definition slang.h:2047
@ SLANG_TEXTURE_2D_MULTISAMPLE_ARRAY
Definition slang.h:2074
@ SLANG_TEXTURE_MULTISAMPLE_FLAG
Definition slang.h:2066
@ SLANG_TEXTURE_ARRAY_FLAG
Definition slang.h:2065
@ SLANG_BYTE_ADDRESS_BUFFER
Definition slang.h:2056
@ SLANG_TEXTURE_SHADOW_FLAG
Definition slang.h:2064
@ SLANG_TEXTURE_2D_ARRAY
Definition slang.h:2070
@ SLANG_TEXTURE_SUBPASS
Definition slang.h:2059
@ SLANG_TEXTURE_CUBE
Definition slang.h:2052
@ SLANG_TEXTURE_3D
Definition slang.h:2051
unsigned int SlangTargetFlags
Flags to control code generation behavior of a compilation target
Definition slang.h:733
uint32_t SlangUInt32
Definition slang.h:542
struct SlangReflectionFunction SlangReflectionFunction
Definition slang.h:1950
SlangUInt32 SlangCooperativeVectorMatrixLayoutIntegral
Definition slang.h:878
unsigned int SlangPathTypeIntegral
Definition slang.h:1589
SlangPathType
Definition slang.h:1591
@ SLANG_PATH_TYPE_DIRECTORY
Definition slang.h:1592
@ SLANG_PATH_TYPE_FILE
Definition slang.h:1593
struct SlangReflectionVariableLayout SlangReflectionVariableLayout
Definition slang.h:1946
SlangUInt32 SlangBindingTypeIntegral
Definition slang.h:2214
SlangUInt32 SlangDebugInfoFormatIntegral
Definition slang.h:900
slang::IGlobalSession SlangSession
An instance of the Slang library.
Definition slang.h:1899
unsigned int SlangFpDenormalModeIntegral
Options to control floating-point denormal handling mode for a target.
Definition slang.h:773
SlangLayoutRules
Definition slang.h:2251
@ SLANG_LAYOUT_RULES_DEFAULT
Definition slang.h:2252
@ SLANG_LAYOUT_RULES_DEFAULT_STRUCTURED_BUFFER
Definition slang.h:2254
@ SLANG_LAYOUT_RULES_METAL_ARGUMENT_BUFFER_TIER_2
Definition slang.h:2253
@ SLANG_LAYOUT_RULES_DEFAULT_CONSTANT_BUFFER
Definition slang.h:2255
int SlangBindableResourceIntegral
Definition slang.h:595
unsigned int SlangTypeKindIntegral
Definition slang.h:1975
SlangReflectionVariableLayout SlangReflectionParameter
Definition slang.h:2287
SlangPassThrough
Definition slang.h:677
@ SLANG_PASS_THROUGH_GLSLANG
Definition slang.h:681
@ SLANG_PASS_THROUGH_SPIRV_OPT
SPIRV-opt
Definition slang.h:690
@ SLANG_PASS_THROUGH_GCC
GCC C/C++ compiler
Definition slang.h:685
@ SLANG_PASS_THROUGH_CLANG
Clang C/C++ compiler
Definition slang.h:683
@ SLANG_PASS_THROUGH_SPIRV_DIS
Definition slang.h:682
@ SLANG_PASS_THROUGH_FXC
Definition slang.h:679
@ SLANG_PASS_THROUGH_DXC
Definition slang.h:680
@ SLANG_PASS_THROUGH_GENERIC_C_CPP
Definition slang.h:686
@ SLANG_PASS_THROUGH_NONE
Definition slang.h:678
@ SLANG_PASS_THROUGH_NVRTC
NVRTC Cuda compiler
Definition slang.h:688
@ SLANG_PASS_THROUGH_TINT
Tint WGSL compiler
Definition slang.h:692
@ SLANG_PASS_THROUGH_METAL
Metal compiler
Definition slang.h:691
@ SLANG_PASS_THROUGH_SPIRV_LINK
SPIRV-link
Definition slang.h:693
@ SLANG_PASS_THROUGH_COUNT_OF
Definition slang.h:694
@ SLANG_PASS_THROUGH_VISUAL_STUDIO
Visual studio C/C++ compiler
Definition slang.h:684
@ SLANG_PASS_THROUGH_LLVM
LLVM 'compiler' - includes LLVM and Clang
Definition slang.h:689
int32_t SlangResult
Definition slang.h:1243
SlangEntryPointLayout SlangReflectionEntryPoint
Definition slang.h:1971
SlangProfileID
Definition slang.h:816
@ SLANG_PROFILE_UNKNOWN
Definition slang.h:817
#define SLANG_NO_THROW
Definition slang.h:212
SlangParameterCategory
Definition slang.h:2095
@ SLANG_PARAMETER_CATEGORY_RAY_PAYLOAD
Definition slang.h:2118
@ SLANG_PARAMETER_CATEGORY_METAL_BUFFER
Definition slang.h:2181
@ SLANG_PARAMETER_CATEGORY_METAL_PAYLOAD
Definition slang.h:2175
@ SLANG_PARAMETER_CATEGORY_COUNT
Definition slang.h:2178
@ SLANG_PARAMETER_CATEGORY_SUB_ELEMENT_REGISTER_SPACE
Definition slang.h:2163
@ SLANG_PARAMETER_CATEGORY_CONSTANT_BUFFER
Definition slang.h:2098
@ SLANG_PARAMETER_CATEGORY_REGISTER_SPACE
Definition slang.h:2110
@ SLANG_PARAMETER_CATEGORY_DESCRIPTOR_TABLE_SLOT
Definition slang.h:2105
@ SLANG_PARAMETER_CATEGORY_EXISTENTIAL_TYPE_PARAM
Definition slang.h:2141
@ SLANG_PARAMETER_CATEGORY_VARYING_OUTPUT
Definition slang.h:2102
@ SLANG_PARAMETER_CATEGORY_COUNT_V1
Definition slang.h:2188
@ SLANG_PARAMETER_CATEGORY_METAL_ARGUMENT_BUFFER_ELEMENT
Definition slang.h:2169
@ SLANG_PARAMETER_CATEGORY_FRAGMENT_OUTPUT
Definition slang.h:2187
@ SLANG_PARAMETER_CATEGORY_VERTEX_INPUT
Definition slang.h:2186
@ SLANG_PARAMETER_CATEGORY_EXISTENTIAL_OBJECT_PARAM
Definition slang.h:2160
@ SLANG_PARAMETER_CATEGORY_METAL_TEXTURE
Definition slang.h:2182
@ SLANG_PARAMETER_CATEGORY_METAL_SAMPLER
Definition slang.h:2183
@ SLANG_PARAMETER_CATEGORY_METAL_ATTRIBUTE
Definition slang.h:2172
@ SLANG_PARAMETER_CATEGORY_MIXED
Definition slang.h:2097
@ SLANG_PARAMETER_CATEGORY_VARYING_INPUT
Definition slang.h:2101
@ SLANG_PARAMETER_CATEGORY_SHADER_RESOURCE
Definition slang.h:2099
@ SLANG_PARAMETER_CATEGORY_NONE
Definition slang.h:2096
@ SLANG_PARAMETER_CATEGORY_HIT_ATTRIBUTES
Definition slang.h:2119
@ SLANG_PARAMETER_CATEGORY_UNORDERED_ACCESS
Definition slang.h:2100
@ SLANG_PARAMETER_CATEGORY_GENERIC
Definition slang.h:2116
@ SLANG_PARAMETER_CATEGORY_CALLABLE_PAYLOAD
Definition slang.h:2120
@ SLANG_PARAMETER_CATEGORY_UNIFORM
Definition slang.h:2104
@ SLANG_PARAMETER_CATEGORY_SAMPLER_STATE
Definition slang.h:2103
@ SLANG_PARAMETER_CATEGORY_SUBPASS
Definition slang.h:2166
@ SLANG_PARAMETER_CATEGORY_PUSH_CONSTANT_BUFFER
Definition slang.h:2107
@ SLANG_PARAMETER_CATEGORY_SHADER_RECORD
Definition slang.h:2121
@ SLANG_PARAMETER_CATEGORY_SPECIALIZATION_CONSTANT
Definition slang.h:2106
SlangWriterMode
Definition slang.h:1827
@ SLANG_WRITER_MODE_TEXT
Definition slang.h:1828
@ SLANG_WRITER_MODE_BINARY
Definition slang.h:1829
SlangContainerFormat
Definition slang.h:666
@ SLANG_CONTAINER_FORMAT_SLANG_MODULE
Definition slang.h:672
@ SLANG_CONTAINER_FORMAT_NONE
Definition slang.h:668
#define SLANG_API
Definition slang.h:255
SlangCooperativeVectorMatrixLayout
Definition slang.h:880
@ SLANG_COOPERATIVE_VECTOR_MATRIX_LAYOUT_TRAINING_OPTIMAL
Definition slang.h:884
@ SLANG_COOPERATIVE_VECTOR_MATRIX_LAYOUT_COLUMN_MAJOR
Definition slang.h:882
@ SLANG_COOPERATIVE_VECTOR_MATRIX_LAYOUT_ROW_MAJOR
Definition slang.h:881
@ SLANG_COOPERATIVE_VECTOR_MATRIX_LAYOUT_INFERENCING_OPTIMAL
Definition slang.h:883
struct SlangEntryPoint SlangEntryPoint
Definition slang.h:1938
SlangUInt32 SlangStageIntegral
Definition slang.h:835
SlangDeclKind
Definition slang.h:2029
@ SLANG_DECL_KIND_STRUCT
Definition slang.h:2031
@ SLANG_DECL_KIND_UNSUPPORTED_FOR_REFLECTION
Definition slang.h:2030
@ SLANG_DECL_KIND_NAMESPACE
Definition slang.h:2036
@ SLANG_DECL_KIND_ENUM
Definition slang.h:2037
@ SLANG_DECL_KIND_GENERIC
Definition slang.h:2034
@ SLANG_DECL_KIND_VARIABLE
Definition slang.h:2035
@ SLANG_DECL_KIND_FUNC
Definition slang.h:2032
@ SLANG_DECL_KIND_MODULE
Definition slang.h:2033
SlangResourceAccess
Definition slang.h:2081
@ SLANG_RESOURCE_ACCESS_FEEDBACK
Definition slang.h:2089
@ SLANG_RESOURCE_ACCESS_NONE
Definition slang.h:2082
@ SLANG_RESOURCE_ACCESS_WRITE
Definition slang.h:2088
@ SLANG_RESOURCE_ACCESS_UNKNOWN
Definition slang.h:2090
@ SLANG_RESOURCE_ACCESS_RASTER_ORDERED
Definition slang.h:2085
@ SLANG_RESOURCE_ACCESS_APPEND
Definition slang.h:2086
@ SLANG_RESOURCE_ACCESS_READ_WRITE
Definition slang.h:2084
@ SLANG_RESOURCE_ACCESS_READ
Definition slang.h:2083
@ SLANG_RESOURCE_ACCESS_CONSUME
Definition slang.h:2087
unsigned int SlangMatrixLayoutModeIntegral
Definition slang.h:827
unsigned int SlangWriterModeIntegral
Definition slang.h:1825
#define SLANG_EXTERN_C
Definition slang.h:351
@ SLANG_COMPILE_FLAG_OBFUSCATE
Definition slang.h:722
@ SLANG_COMPILE_FLAG_NO_MANGLING
Definition slang.h:716
@ SLANG_COMPILE_FLAG_NO_CODEGEN
Definition slang.h:719
@ SLANG_COMPILE_FLAG_NO_CHECKING
Definition slang.h:727
@ SLANG_COMPILE_FLAG_SPLIT_MIXED_TYPES
Definition slang.h:728
SlangLineDirectiveMode
Definition slang.h:786
@ SLANG_LINE_DIRECTIVE_MODE_NONE
Definition slang.h:789
@ SLANG_LINE_DIRECTIVE_MODE_SOURCE_MAP
Definition slang.h:793
@ SLANG_LINE_DIRECTIVE_MODE_STANDARD
Definition slang.h:790
@ SLANG_LINE_DIRECTIVE_MODE_DEFAULT
Definition slang.h:787
@ SLANG_LINE_DIRECTIVE_MODE_GLSL
Definition slang.h:791
#define SLANG_FORCE_INLINE
Definition slang.h:291
unsigned int SlangScalarTypeIntegral
Definition slang.h:2002
struct slang::ICompileRequest SlangCompileRequest
A request for one or more compilation actions to be performed.
Definition slang.h:1907
SlangImageFormat
Definition slang.h:2276
SlangReflectionGenericArgType
Definition slang.h:1961
@ SLANG_GENERIC_ARG_BOOL
Definition slang.h:1964
@ SLANG_GENERIC_ARG_TYPE
Definition slang.h:1962
@ SLANG_GENERIC_ARG_INT
Definition slang.h:1963
struct SlangReflectionUserAttribute SlangReflectionUserAttribute
Definition slang.h:1948
int SlangCompileTargetIntegral
Definition slang.h:613
void(* SlangDiagnosticCallback)(char const *message, void *userData)
Callback type used for diagnostic output.
Definition slang.h:1913
@ SLANG_TARGET_FLAG_GENERATE_WHOLE_PROGRAM
Definition slang.h:747
@ SLANG_TARGET_FLAG_PARAMETER_BLOCKS_USE_REGISTER_SPACES
Definition slang.h:741
@ SLANG_TARGET_FLAG_GENERATE_SPIRV_DIRECTLY
Definition slang.h:754
@ SLANG_TARGET_FLAG_DUMP_IR
Definition slang.h:750
SlangSourceLanguage
Definition slang.h:799
@ SLANG_SOURCE_LANGUAGE_HLSL
Definition slang.h:802
@ SLANG_SOURCE_LANGUAGE_METAL
Definition slang.h:808
@ SLANG_SOURCE_LANGUAGE_GLSL
Definition slang.h:803
@ SLANG_SOURCE_LANGUAGE_WGSL
Definition slang.h:809
@ SLANG_SOURCE_LANGUAGE_SPIRV
Definition slang.h:807
@ SLANG_SOURCE_LANGUAGE_COUNT_OF
Definition slang.h:811
@ SLANG_SOURCE_LANGUAGE_CUDA
Definition slang.h:806
@ SLANG_SOURCE_LANGUAGE_CPP
Definition slang.h:805
@ SLANG_SOURCE_LANGUAGE_UNKNOWN
Definition slang.h:800
@ SLANG_SOURCE_LANGUAGE_C
Definition slang.h:804
@ SLANG_SOURCE_LANGUAGE_LLVM
Definition slang.h:810
@ SLANG_SOURCE_LANGUAGE_SLANG
Definition slang.h:801
SLANG_API const char * spGetBuildTagString()
Get the build version 'tag' string. The string is the same as produced via git describe --tags --matc...
int SlangArchiveTypeIntegral
Definition slang.h:698
uint32_t SlangSizeT
Definition slang.h:563
struct SlangReflectionTypeParameter SlangReflectionTypeParameter
Definition slang.h:1947
SlangUInt32 SlangScopeIntegral
Definition slang.h:861
int SlangSeverityIntegral
Severity of a diagnostic generated by the compiler. Values come from the enum below,...
Definition slang.h:575
SlangCapabilityID
Definition slang.h:823
@ SLANG_CAPABILITY_UNKNOWN
Definition slang.h:824
SlangMatrixLayoutMode
Definition slang.h:829
@ SLANG_MATRIX_LAYOUT_MODE_UNKNOWN
Definition slang.h:830
@ SLANG_MATRIX_LAYOUT_ROW_MAJOR
Definition slang.h:831
@ SLANG_MATRIX_LAYOUT_COLUMN_MAJOR
Definition slang.h:832
SlangUInt32 SlangCooperativeMatrixUseIntegral
Definition slang.h:870
SlangArchiveType
Definition slang.h:700
@ SLANG_ARCHIVE_TYPE_RIFF
Riff container with no compression
Definition slang.h:703
@ SLANG_ARCHIVE_TYPE_ZIP
Definition slang.h:702
@ SLANG_ARCHIVE_TYPE_COUNT_OF
Definition slang.h:706
@ SLANG_ARCHIVE_TYPE_UNDEFINED
Definition slang.h:701
@ SLANG_ARCHIVE_TYPE_RIFF_DEFLATE
Definition slang.h:704
@ SLANG_ARCHIVE_TYPE_RIFF_LZ4
Definition slang.h:705
OSPathKind
Definition slang.h:1604
@ None
Paths do not map to the file system
@ Direct
Paths map directly to the file system
SlangDebugInfoLevel
Definition slang.h:889
@ SLANG_DEBUG_INFO_LEVEL_STANDARD
Definition slang.h:893
@ SLANG_DEBUG_INFO_LEVEL_MINIMAL
Definition slang.h:891
@ SLANG_DEBUG_INFO_LEVEL_MAXIMAL
Definition slang.h:895
@ SLANG_DEBUG_INFO_LEVEL_NONE
Definition slang.h:890
struct SlangReflectionDecl SlangReflectionDecl
Definition slang.h:1941
SlangBindingType
Definition slang.h:2216
@ SLANG_BINDING_TYPE_MUTABLE_FLAG
Definition slang.h:2236
@ SLANG_BINDING_TYPE_VARYING_OUTPUT
Definition slang.h:2231
@ SLANG_BINDING_TYPE_BASE_MASK
Definition slang.h:2245
@ SLANG_BINDING_TYPE_TEXTURE
Definition slang.h:2220
@ SLANG_BINDING_TYPE_MUTABLE_TETURE
Definition slang.h:2238
@ SLANG_BINDING_TYPE_VARYING_INPUT
Definition slang.h:2230
@ SLANG_BINDING_TYPE_MUTABLE_RAW_BUFFER
Definition slang.h:2242
@ SLANG_BINDING_TYPE_TYPED_BUFFER
Definition slang.h:2223
@ SLANG_BINDING_TYPE_CONSTANT_BUFFER
Definition slang.h:2221
@ SLANG_BINDING_TYPE_MUTABLE_TYPED_BUFFER
Definition slang.h:2240
@ SLANG_BINDING_TYPE_EXT_MASK
Definition slang.h:2246
@ SLANG_BINDING_TYPE_PUSH_CONSTANT
Definition slang.h:2234
@ SLANG_BINDING_TYPE_RAY_TRACING_ACCELERATION_STRUCTURE
Definition slang.h:2228
@ SLANG_BINDING_TYPE_COMBINED_TEXTURE_SAMPLER
Definition slang.h:2225
@ SLANG_BINDING_TYPE_INPUT_RENDER_TARGET
Definition slang.h:2226
@ SLANG_BINDING_TYPE_PARAMETER_BLOCK
Definition slang.h:2222
@ SLANG_BINDING_TYPE_UNKNOWN
Definition slang.h:2217
@ SLANG_BINDING_TYPE_SAMPLER
Definition slang.h:2219
@ SLANG_BINDING_TYPE_INLINE_UNIFORM_DATA
Definition slang.h:2227
@ SLANG_BINDING_TYPE_EXISTENTIAL_VALUE
Definition slang.h:2233
@ SLANG_BINDING_TYPE_RAW_BUFFER
Definition slang.h:2224
struct SlangProgramLayout SlangProgramLayout
Definition slang.h:1902
uint32_t SlangUInt
Definition slang.h:560
unsigned int SlangDeclKindIntegral
Definition slang.h:2027
SlangStage
Definition slang.h:837
@ SLANG_STAGE_VERTEX
Definition slang.h:839
@ SLANG_STAGE_CALLABLE
Definition slang.h:850
@ SLANG_STAGE_COUNT
Definition slang.h:855
@ SLANG_STAGE_FRAGMENT
Definition slang.h:843
@ SLANG_STAGE_NONE
Definition slang.h:838
@ SLANG_STAGE_CLOSEST_HIT
Definition slang.h:848
@ SLANG_STAGE_RAY_GENERATION
Definition slang.h:845
@ SLANG_STAGE_HULL
Definition slang.h:840
@ SLANG_STAGE_COMPUTE
Definition slang.h:844
@ SLANG_STAGE_MISS
Definition slang.h:849
@ SLANG_STAGE_AMPLIFICATION
Definition slang.h:852
@ SLANG_STAGE_ANY_HIT
Definition slang.h:847
@ SLANG_STAGE_PIXEL
Definition slang.h:858
@ SLANG_STAGE_DISPATCH
Definition slang.h:853
@ SLANG_STAGE_MESH
Definition slang.h:851
@ SLANG_STAGE_GEOMETRY
Definition slang.h:842
@ SLANG_STAGE_INTERSECTION
Definition slang.h:846
@ SLANG_STAGE_DOMAIN
Definition slang.h:841
int SlangSourceLanguageIntegral
Definition slang.h:797
struct SlangEntryPointLayout SlangEntryPointLayout
Definition slang.h:1939
SlangUInt32 SlangModifierIDIntegral
Definition slang.h:2258
unsigned int SlangWriterChannelIntegral
Definition slang.h:1816
SlangCompileTarget
Definition slang.h:615
@ SLANG_TARGET_COUNT_OF
Definition slang.h:658
@ SLANG_HOST_SHARED_LIBRARY
A shared library/Dll for host code (for hosting CPU/OS)
Definition slang.h:645
@ SLANG_OBJECT_CODE
Object code that can be used for later linking (kernel/shader)
Definition slang.h:638
@ SLANG_CPP_PYTORCH_BINDING
C++ PyTorch binding code.
Definition slang.h:641
@ SLANG_SHADER_SHARED_LIBRARY
Definition slang.h:631
@ SLANG_HLSL
Definition slang.h:621
@ SLANG_HOST_HOST_CALLABLE
Host callable host code (ie non kernel/shader)
Definition slang.h:640
@ SLANG_SPIRV_ASM
Definition slang.h:623
@ SLANG_SPIRV
Definition slang.h:622
@ SLANG_DXIL
Definition slang.h:626
@ SLANG_HOST_LLVM_IR
Host LLVM IR assembly
Definition slang.h:655
@ SLANG_DXBC_ASM
Definition slang.h:625
@ SLANG_CPP_SOURCE
C++ code for shader kernels.
Definition slang.h:629
@ SLANG_WGSL
WebGPU shading language
Definition slang.h:646
@ SLANG_TARGET_UNKNOWN
Definition slang.h:616
@ SLANG_METAL_LIB_ASM
Metal library assembly
Definition slang.h:644
@ SLANG_METAL_LIB
Metal library
Definition slang.h:643
@ SLANG_C_SOURCE
The C language
Definition slang.h:628
@ SLANG_GLSL
Definition slang.h:618
@ SLANG_HOST_VM
Bytecode that can be interpreted by the Slang VM
Definition slang.h:650
@ SLANG_WGSL_SPIRV
SPIR-V via WebGPU shading language
Definition slang.h:648
@ SLANG_HOST_EXECUTABLE
Standalone binary executable (for hosting CPU/OS)
Definition slang.h:630
@ SLANG_CUDA_OBJECT_CODE
Object code that contains CUDA functions.
Definition slang.h:637
@ SLANG_SHADER_HOST_CALLABLE
Definition slang.h:633
@ SLANG_PTX
PTX
Definition slang.h:636
@ SLANG_CUDA_HEADER
Cuda header
Definition slang.h:652
@ SLANG_HOST_CPP_SOURCE
C++ code for host library or executable.
Definition slang.h:639
@ SLANG_GLSL_VULKAN_ONE_DESC_DEPRECATED
Definition slang.h:620
@ SLANG_WGSL_SPIRV_ASM
SPIR-V assembly via WebGPU shading language
Definition slang.h:647
@ SLANG_CUDA_SOURCE
Cuda source
Definition slang.h:635
@ SLANG_DXBC
Definition slang.h:624
@ SLANG_TARGET_NONE
Definition slang.h:617
@ SLANG_CPP_HEADER
C++ header for shader kernels.
Definition slang.h:651
@ SLANG_GLSL_VULKAN_DEPRECATED
Definition slang.h:619
@ SLANG_DXIL_ASM
Definition slang.h:627
@ SLANG_HOST_OBJECT_CODE
Host object code
Definition slang.h:654
@ SLANG_METAL
Metal shading language
Definition slang.h:642
@ SLANG_SHADER_LLVM_IR
Host LLVM IR assembly (kernel/shader)
Definition slang.h:656
PathKind
Definition slang.h:1613
SlangUInt32 SlangImageFormatIntegral
Definition slang.h:2274
SlangOptimizationLevel
Definition slang.h:918
@ SLANG_OPTIMIZATION_LEVEL_NONE
Definition slang.h:919
@ SLANG_OPTIMIZATION_LEVEL_MAXIMAL
Definition slang.h:923
@ SLANG_OPTIMIZATION_LEVEL_HIGH
Definition slang.h:922
@ SLANG_OPTIMIZATION_LEVEL_DEFAULT
Definition slang.h:920
#define SLANG_UNKNOWN_SIZE
Definition slang.h:2283
unsigned int SlangParameterCategoryIntegral
Definition slang.h:2093
SlangUInt32 SlangLayoutRulesIntegral
Definition slang.h:2249
SlangBindableResourceType
Definition slang.h:597
@ SLANG_TEXTURE
Definition slang.h:599
@ SLANG_STORAGE_BUFFER
Definition slang.h:602
@ SLANG_SAMPLER
Definition slang.h:600
@ SLANG_NON_BINDABLE
Definition slang.h:598
@ SLANG_UNIFORM_BUFFER
Definition slang.h:601
struct SlangReflectionType SlangReflectionType
Definition slang.h:1943
SlangFpDenormalMode
Definition slang.h:775
@ SLANG_FP_DENORM_MODE_PRESERVE
Definition slang.h:777
@ SLANG_FP_DENORM_MODE_FTZ
Definition slang.h:778
@ SLANG_FP_DENORM_MODE_ANY
Definition slang.h:776
struct SlangReflectionVariable SlangReflectionVariable
Definition slang.h:1945
int32_t SlangInt32
Definition slang.h:543
int32_t SlangSSizeT
Definition slang.h:562
SlangDiagnosticColor
Definition slang.h:943
@ SLANG_DIAGNOSTIC_COLOR_NEVER
Definition slang.h:946
@ SLANG_DIAGNOSTIC_COLOR_AUTO
Definition slang.h:944
@ SLANG_DIAGNOSTIC_COLOR_ALWAYS
Definition slang.h:945
SlangCooperativeMatrixUse
Definition slang.h:872
@ SLANG_COOPERATIVE_MATRIX_USE_A
Definition slang.h:873
@ SLANG_COOPERATIVE_MATRIX_USE_B
Definition slang.h:874
@ SLANG_COOPERATIVE_MATRIX_USE_ACCUMULATOR
Definition slang.h:875
#define SLANG_DEPRECATED
Definition slang.h:527
SlangFloatingPointMode
Definition slang.h:764
@ SLANG_FLOATING_POINT_MODE_PRECISE
Definition slang.h:767
@ SLANG_FLOATING_POINT_MODE_DEFAULT
Definition slang.h:765
@ SLANG_FLOATING_POINT_MODE_FAST
Definition slang.h:766
SlangScalarType
Definition slang.h:2004
@ SLANG_SCALAR_TYPE_UINTPTR
Definition slang.h:2020
@ SLANG_SCALAR_TYPE_FLOAT16
Definition slang.h:2012
@ SLANG_SCALAR_TYPE_BOOL
Definition slang.h:2007
@ SLANG_SCALAR_TYPE_BFLOAT16
Definition slang.h:2021
@ SLANG_SCALAR_TYPE_INT8
Definition slang.h:2015
@ SLANG_SCALAR_TYPE_UINT16
Definition slang.h:2018
@ SLANG_SCALAR_TYPE_FLOAT64
Definition slang.h:2014
@ SLANG_SCALAR_TYPE_NONE
Definition slang.h:2005
@ SLANG_SCALAR_TYPE_UINT32
Definition slang.h:2009
@ SLANG_SCALAR_TYPE_VOID
Definition slang.h:2006
@ SLANG_SCALAR_TYPE_INT64
Definition slang.h:2010
@ SLANG_SCALAR_TYPE_FLOAT_E4M3
Definition slang.h:2022
@ SLANG_SCALAR_TYPE_INT32
Definition slang.h:2008
@ SLANG_SCALAR_TYPE_UINT8
Definition slang.h:2016
@ SLANG_SCALAR_TYPE_INT16
Definition slang.h:2017
@ SLANG_SCALAR_TYPE_FLOAT_E5M2
Definition slang.h:2023
@ SLANG_SCALAR_TYPE_UINT64
Definition slang.h:2011
@ SLANG_SCALAR_TYPE_INTPTR
Definition slang.h:2019
@ SLANG_SCALAR_TYPE_FLOAT32
Definition slang.h:2013
SlangUInt32 SlangDebugInfoLevelIntegral
Definition slang.h:887
SlangReflectionUserAttribute SlangReflectionAttribute
Definition slang.h:1949
SlangInt32 SlangCapabilityIDIntegral
Definition slang.h:821
struct SlangReflectionTypeLayout SlangReflectionTypeLayout
Definition slang.h:1944
SlangTypeKind
Definition slang.h:1977
@ SLANG_TYPE_KIND_SHADER_STORAGE_BUFFER
Definition slang.h:1988
@ SLANG_TYPE_KIND_MESH_OUTPUT
Definition slang.h:1993
@ SLANG_TYPE_KIND_SPECIALIZED
Definition slang.h:1994
@ SLANG_TYPE_KIND_VECTOR
Definition slang.h:1982
@ SLANG_TYPE_KIND_POINTER
Definition slang.h:1996
@ SLANG_TYPE_KIND_TEXTURE_BUFFER
Definition slang.h:1987
@ SLANG_TYPE_KIND_ENUM
Definition slang.h:1998
@ SLANG_TYPE_KIND_OUTPUT_STREAM
Definition slang.h:1992
@ SLANG_TYPE_KIND_ARRAY
Definition slang.h:1980
@ SLANG_TYPE_KIND_STRUCT
Definition slang.h:1979
@ SLANG_TYPE_KIND_FEEDBACK
Definition slang.h:1995
@ SLANG_TYPE_KIND_CONSTANT_BUFFER
Definition slang.h:1984
@ SLANG_TYPE_KIND_COUNT
Definition slang.h:1999
@ SLANG_TYPE_KIND_DYNAMIC_RESOURCE
Definition slang.h:1997
@ SLANG_TYPE_KIND_MATRIX
Definition slang.h:1981
@ SLANG_TYPE_KIND_GENERIC_TYPE_PARAMETER
Definition slang.h:1990
@ SLANG_TYPE_KIND_RESOURCE
Definition slang.h:1985
@ SLANG_TYPE_KIND_SAMPLER_STATE
Definition slang.h:1986
@ SLANG_TYPE_KIND_PARAMETER_BLOCK
Definition slang.h:1989
@ SLANG_TYPE_KIND_NONE
Definition slang.h:1978
@ SLANG_TYPE_KIND_SCALAR
Definition slang.h:1983
@ SLANG_TYPE_KIND_INTERFACE
Definition slang.h:1991
SlangDebugInfoFormat
Definition slang.h:902
@ SLANG_DEBUG_INFO_FORMAT_STABS
Stabs
Definition slang.h:908
@ SLANG_DEBUG_INFO_FORMAT_DEFAULT
Use the default debugging format for the target
Definition slang.h:903
@ SLANG_DEBUG_INFO_FORMAT_C7
Definition slang.h:904
@ SLANG_DEBUG_INFO_FORMAT_COUNT_OF
Definition slang.h:913
@ SLANG_DEBUG_INFO_FORMAT_DWARF
Definition slang.h:910
@ SLANG_DEBUG_INFO_FORMAT_PDB
Program database
Definition slang.h:906
@ SLANG_DEBUG_INFO_FORMAT_COFF
COFF debug info
Definition slang.h:909
SlangUInt32 SlangOptimizationLevelIntegral
Definition slang.h:916
SlangScope
Definition slang.h:863
@ SLANG_SCOPE_WAVE
Definition slang.h:866
@ SLANG_SCOPE_THREAD
Definition slang.h:865
@ SLANG_SCOPE_NONE
Definition slang.h:864
@ SLANG_SCOPE_THREAD_GROUP
Definition slang.h:867
unsigned int SlangResourceAccessIntegral
Definition slang.h:2079
int SlangContainerFormatIntegral
Definition slang.h:664
@ SLANG_DIAGNOSTIC_FLAG_VERBOSE_PATHS
Definition slang.h:591
@ SLANG_DIAGNOSTIC_FLAG_TREAT_WARNINGS_AS_ERRORS
Definition slang.h:592
constexpr SlangTargetFlags kDefaultTargetFlags
Definition slang.h:756
#define SLANG_MCALL
Definition slang.h:226
unsigned int SlangCompileFlags
Definition slang.h:712
void(* FileSystemContentsCallBack)(SlangPathType pathType, const char *name, void *userData)
Definition slang.h:1600
SlangWriterChannel
Definition slang.h:1818
@ SLANG_WRITER_CHANNEL_COUNT_OF
Definition slang.h:1822
@ SLANG_WRITER_CHANNEL_STD_ERROR
Definition slang.h:1821
@ SLANG_WRITER_CHANNEL_STD_OUTPUT
Definition slang.h:1820
@ SLANG_WRITER_CHANNEL_DIAGNOSTIC
Definition slang.h:1819
void(* SlangFuncPtr)(void)
Definition slang.h:1524
int SlangPassThroughIntegral
Definition slang.h:675
SlangProgramLayout SlangReflection
Definition slang.h:1970
unsigned int SlangResourceShapeIntegral
Definition slang.h:2042
SlangEmitSpirvMethod
Definition slang.h:929
@ SLANG_EMIT_SPIRV_VIA_GLSL
Definition slang.h:931
@ SLANG_EMIT_SPIRV_DIRECTLY
Definition slang.h:932
@ SLANG_EMIT_SPIRV_DEFAULT
Definition slang.h:930
SlangModifierID
Definition slang.h:2260
@ SLANG_MODIFIER_DIFFERENTIABLE
Definition slang.h:2267
@ SLANG_MODIFIER_STATIC
Definition slang.h:2263
@ SLANG_MODIFIER_SHARED
Definition slang.h:2261
@ SLANG_MODIFIER_IN
Definition slang.h:2269
@ SLANG_MODIFIER_EXPORT
Definition slang.h:2265
@ SLANG_MODIFIER_CONST
Definition slang.h:2264
@ SLANG_MODIFIER_OUT
Definition slang.h:2270
@ SLANG_MODIFIER_EXTERN
Definition slang.h:2266
@ SLANG_MODIFIER_INOUT
Definition slang.h:2271
@ SLANG_MODIFIER_MUTATING
Definition slang.h:2268
@ SLANG_MODIFIER_NO_DIFF
Definition slang.h:2262
Definition slang-cpp-types-core.h:82
virtual SLANG_NO_THROW size_t SLANG_MCALL getBufferSize()=0
SLANG_COM_INTERFACE(0x8BA5FB08, 0x5195, 0x40e2, {0xAC, 0x58, 0x0D, 0x98, 0x9C, 0x3A, 0x01, 0x02}) virtual SLANG_NO_THROW void const *SLANG_MCALL getBufferPointer()=0
SLANG_COM_INTERFACE(0x5fb632d2, 0x979d, 0x4481, {0x9f, 0xee, 0x66, 0x3c, 0x3f, 0x14, 0x49, 0xe1}) virtual SLANG_NO_THROW SlangResult SLANG_MCALL getFileUniqueIdentity(const char *path
virtual SLANG_NO_THROW SlangResult SLANG_MCALL enumeratePathContents(const char *path, FileSystemContentsCallBack callback, void *userData)=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL calcCombinedPath(SlangPathType fromPathType, const char *fromPath, const char *path, ISlangBlob **pathOut)=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL getPath(PathKind kind, const char *path, ISlangBlob **outPath)=0
virtual SLANG_NO_THROW OSPathKind SLANG_MCALL getOSPathKind()=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL getPathType(const char *path, SlangPathType *pathTypeOut)=0
virtual SLANG_NO_THROW void SLANG_MCALL clearCache()=0
ISlangBlob ** outUniqueIdentity
Definition slang.h:1693
SLANG_COM_INTERFACE(0x003A09FC, 0x3A4D, 0x4BA0, {0xAD, 0x60, 0x1F, 0xD8, 0x63, 0xA9, 0x15, 0xAB}) virtual SLANG_NO_THROW SlangResult SLANG_MCALL loadFile(char const *path
ISlangBlob ** outBlob
Definition slang.h:1519
virtual SLANG_NO_THROW SlangResult SLANG_MCALL createDirectory(const char *path)=0
const void * data
Definition slang.h:1776
virtual SLANG_NO_THROW SlangResult SLANG_MCALL remove(const char *path)=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL saveFileBlob(const char *path, ISlangBlob *dataBlob)=0
SLANG_COM_INTERFACE(0xa058675c, 0x1d65, 0x452a, {0x84, 0x58, 0xcc, 0xde, 0xd1, 0x42, 0x71, 0x5}) virtual SLANG_NO_THROW SlangResult SLANG_MCALL saveFile(const char *path
const void size_t size
Definition slang.h:1776
SLANG_COM_INTERFACE(0x197772c7, 0x0155, 0x4b91, {0x84, 0xe8, 0x66, 0x68, 0xba, 0xff, 0x06, 0x19}) virtual SLANG_NO_THROW size_t SLANG_MCALL getEntryCount()=0
virtual SLANG_NO_THROW long SLANG_MCALL getEntryTimeMS(uint32_t index)=0
virtual SLANG_NO_THROW const char *SLANG_MCALL getEntryName(uint32_t index)=0
virtual SLANG_NO_THROW uint32_t SLANG_MCALL getEntryInvocationTimes(uint32_t index)=0
SLANG_COM_INTERFACE(0x9c9d5bc5, 0xeb61, 0x496f, {0x80, 0xd7, 0xd1, 0x47, 0xc4, 0xa2, 0x37, 0x30}) virtual SLANG_NO_THROW void *SLANG_MCALL findSymbolAddressByName(char const *name)=0
virtual SLANG_NO_THROW void *SLANG_MCALL findSymbolAddressByName(char const *name)=0
SLANG_COM_INTERFACE(0x70dbc7c4, 0xdc3b, 0x4a07, {0xae, 0x7e, 0x75, 0x2a, 0xf6, 0xa8, 0x15, 0x55}) SLANG_FORCE_INLINE SlangFuncPtr findFuncByName(char const *name)
Definition slang.h:1546
ISlangSharedLibrary ** sharedLibraryOut
Definition slang.h:1584
SLANG_COM_INTERFACE(0x6264ab2b, 0xa3e8, 0x4a06, {0x97, 0xf1, 0x49, 0xbc, 0x2d, 0x2a, 0xb1, 0x4d}) virtual SLANG_NO_THROW SlangResult SLANG_MCALL loadSharedLibrary(const char *path
Definition slang-cpp-prelude.h:303
SlangResult QueryInterface(struct _GUID const &uuid, void **outObject)
Definition slang.h:1414
void ** outObject
Definition slang.h:1406
virtual SLANG_NO_THROW uint32_t SLANG_MCALL addRef()=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL queryInterface(SlangUUID const &uuid, void **outObject)=0
virtual SLANG_NO_THROW uint32_t SLANG_MCALL release()=0
SLANG_COM_INTERFACE(0x00000000, 0x0000, 0x0000, {0xC0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x46}) virtual SLANG_NO_THROW SlangResult SLANG_MCALL queryInterface(SlangUUID const &uuid
uint32_t AddRef()
Definition slang.h:1418
uint32_t Release()
Definition slang.h:1419
virtual SLANG_NO_THROW SlangResult SLANG_MCALL endAppendBuffer(char *buffer, size_t numChars)=0
virtual SLANG_NO_THROW SlangBool SLANG_MCALL isConsole()=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL write(const char *chars, size_t numChars)=0
SLANG_COM_INTERFACE(0xec457f0e, 0x9add, 0x4e6b, {0x85, 0x1c, 0xd7, 0xfa, 0x71, 0x6d, 0x15, 0xfd}) virtual SLANG_NO_THROW char *SLANG_MCALL beginAppendBuffer(size_t maxNumChars)=0
virtual SLANG_NO_THROW SlangResult SLANG_MCALL setMode(SlangWriterMode mode)=0
virtual SLANG_NO_THROW void SLANG_MCALL flush()=0
Definition slang-cpp-types-core.h:401
Definition slang-cpp-types.h:240
char chars[1]
Definition slang.h:1483
SLANG_CLASS_GUID(0xbe0db1a8, 0x3594, 0x4603, {0xa7, 0x8b, 0xc4, 0x86, 0x84, 0x30, 0xdf, 0xbb})
Definition slang-cpp-prelude.h:293
uint16_t data3
Definition slang-cpp-prelude.h:296
uint32_t data1
Definition slang-cpp-prelude.h:294
uint16_t data2
Definition slang-cpp-prelude.h:295
uint8_t data4[8]
Definition slang-cpp-prelude.h:297
Definition slang-cpp-types.h:61
Definition slang-cpp-types-core.h:103
CompilerOptionName name
Definition slang.h:1198
CompilerOptionValue value
Definition slang.h:1199
int32_t intValue0
Definition slang.h:1190
const char * stringValue1
Definition slang.h:1193
int32_t intValue1
Definition slang.h:1191
const char * stringValue0
Definition slang.h:1192
CompilerOptionValueKind kind
Definition slang.h:1189
int64_t intVal
Definition slang.h:1956
SlangReflectionType * typeVal
Definition slang.h:1955
bool boolVal
Definition slang.h:1957