https://github.com/shader-slang/slang
Raw File
Tip revision: 6992d0e3eb7eab04f05da99adcf437cfdbfbbb79 authored by Tim Foley on 21 July 2017, 19:31:18 UTC
Merge pull request #134 from tfoleyNV/gh-133
Tip revision: 6992d0e
gh-122.slang
//TEST:CROSS_COMPILE: -profile ps_5_0 -entry main -target spirv-assembly

// Ensure that `GetDimensions` with `mipCount` output works
// on a `Texture2D`

layout(binding = 1)
Texture2D t;

float4 main() : SV_Target
{
	uint x, y, mipCount;
    t.GetDimensions(0, x, y, mipCount);

    return float4(x, y, mipCount, 0);
}
back to top