yum-mirror/slang
Making it easier to work with shaders
git clone https://git.yummers.dev/yum-mirror/slang
f02b08490
master
1//TEST(compute, vulkan):COMPARE_COMPUTE(filecheck-buffer=BUF):-vk -compute -entry computeMain 2//TEST(compute, vulkan):COMPARE_COMPUTE(filecheck-buffer=BUF):-vk -compute -entry computeMain -emit-spirv-directly 3//TEST(compute, vulkan):COMPARE_COMPUTE(filecheck-buffer=BUF):-cpu -compute -entry computeMain 4//TEST(smoke,compute):COMPARE_COMPUTE(filecheck-buffer=BUF):-dx12 -compute -entry computeMain 5 6//TEST_INPUT:ubuffer(data=[0], stride=4):out,name=outputBuffer 7RWStructuredBuffer<int> outputBuffer; 8 9struct TextureHandle 10{ 11 uint32_t packedData = 0; 12 __init(uint32_t packedData) { this.packedData = packedData; } 13}; 14 15[numthreads(1, 1, 1)] 16void computeMain(uint3 dispatchThreadID: SV_DispatchThreadID) 17{ 18 TextureHandle texHandle = TextureHandle(1); 19 // BUF: 1 20 outputBuffer[0] = true 21 && texHandle.packedData == 1 22 ; 23}