diff options
| author | Jay Kwak <82421531+jkwak-work@users.noreply.github.com> | 2024-06-11 07:05:46 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-06-11 07:05:46 -0700 |
| commit | df0a201d85eac4c55c1abf15ed0bf9baea0ae971 (patch) | |
| tree | 2ee9aa509fd9da80c9be0d5647c181bde41fa0b3 /source/slang/glsl.meta.slang | |
| parent | 51d358546424646f60f1b214378a366ebb077d03 (diff) | |
Support integer typed textures for GLSL (#4329)
* Support integer typed textures for GLSL
This commit re-enables the ability to sample from an integer typed
texture for GLSL functions while keeping it unavailable for HLSL target.
Diffstat (limited to 'source/slang/glsl.meta.slang')
| -rw-r--r-- | source/slang/glsl.meta.slang | 129 |
1 files changed, 65 insertions, 64 deletions
diff --git a/source/slang/glsl.meta.slang b/source/slang/glsl.meta.slang index 1daf0ec07..db5f9c2fa 100644 --- a/source/slang/glsl.meta.slang +++ b/source/slang/glsl.meta.slang @@ -1878,7 +1878,7 @@ public ivec3 textureSize(Sampler2DMSArray<vector<T,N>,sampleCount> sampler) // textureQueryLod // ------------------- -__generic<T:IFloat, let isArray:int, let sampleCount:int, let isShadow:int, let format:int> +__generic<T, let isArray:int, let sampleCount:int, let isShadow:int, let format:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_querylod)] public vec2 textureQueryLod(__TextureImpl< @@ -1910,10 +1910,11 @@ public vec2 textureQueryLod(__TextureImpl< } } -__generic<T:IFloat, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let isShadow:int, let format:int> +__generic<T, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let isShadow:int, let format:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_querylod)] -public vec2 textureQueryLod(__TextureImpl<T, +public vec2 textureQueryLod(__TextureImpl< + T, Shape, isArray, 0, // isMS @@ -2086,10 +2087,10 @@ public int textureQueryLevels(samplerCubeArrayShadow sampler) // textureSamples // ------------------- -__generic<T:__BuiltinArithmeticType, let N:int, let sampleCount:int> +__generic<T, let sampleCount:int> [ForceInline] [require(glsl_hlsl_spirv, image_samples)] -public int textureSamples(Sampler2DMS<vector<T,N>,sampleCount> sampler) +public int textureSamples(Sampler2DMS<T,sampleCount> sampler) { vector<int,2> dim; int sampleCount; @@ -2098,10 +2099,10 @@ public int textureSamples(Sampler2DMS<vector<T,N>,sampleCount> sampler) return sampleCount; } -__generic<T:__BuiltinArithmeticType, let N:int, let sampleCount:int> +__generic<T, let sampleCount:int> [ForceInline] [require(glsl_hlsl_spirv, image_samples)] -public int textureSamples(Sampler2DMSArray<vector<T,N>,sampleCount> sampler) +public int textureSamples(Sampler2DMSArray<T,sampleCount> sampler) { vector<int,3> dim; int sampleCount; @@ -2118,7 +2119,7 @@ public int textureSamples(Sampler2DMSArray<vector<T,N>,sampleCount> sampler) // texture // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> texture(Sampler1D<vector<T,N>> sampler, float p) @@ -2126,7 +2127,7 @@ public vector<T,4> texture(Sampler1D<vector<T,N>> sampler, float p) return __vectorReshape<4>(sampler.Sample(p)); } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> texture(Sampler1D<vector<T,N>> sampler, float p, constexpr float bias) @@ -2134,7 +2135,7 @@ public vector<T,4> texture(Sampler1D<vector<T,N>> sampler, float p, constexpr fl return __vectorReshape<4>(sampler.SampleBias(p, bias)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> texture(__TextureImpl< @@ -2152,7 +2153,7 @@ public vector<T,4> texture(__TextureImpl< return __vectorReshape<4>(sampler.Sample(p)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> texture(__TextureImpl< @@ -2304,7 +2305,7 @@ public float texture(samplerCubeArrayShadow sampler, vec4 p, float compare) // textureProj // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec2 p) @@ -2321,7 +2322,7 @@ public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec2 p) } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec2 p, float bias) @@ -2338,7 +2339,7 @@ public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec2 p, float bia } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec4 p) @@ -2355,7 +2356,7 @@ public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec4 p) } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec4 p, float bias) @@ -2372,7 +2373,7 @@ public vector<T,4> textureProj(Sampler1D<vector<T,N>> sampler, vec4 p, float bia } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec3 p) @@ -2389,7 +2390,7 @@ public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec3 p) } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec3 p, float bias) @@ -2406,7 +2407,7 @@ public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec3 p, float bia } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec4 p) @@ -2423,7 +2424,7 @@ public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec4 p) } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec4 p, float bias) @@ -2440,7 +2441,7 @@ public vector<T,4> textureProj(Sampler2D<vector<T,N>> sampler, vec4 p, float bia } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler3D<vector<T,N>> sampler, vec4 p) @@ -2457,7 +2458,7 @@ public vector<T,4> textureProj(Sampler3D<vector<T,N>> sampler, vec4 p) } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProj(Sampler3D<vector<T,N>> sampler, vec4 p, float bias) @@ -2562,7 +2563,7 @@ public float textureProj(sampler2DShadow sampler, vec4 p, float bias) // textureLod // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureLod(Sampler1D<vector<T,N>> sampler, float p, float lod) @@ -2570,7 +2571,7 @@ public vector<T,4> textureLod(Sampler1D<vector<T,N>> sampler, float p, float lod return __vectorReshape<4>(sampler.SampleLevel(p, lod)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape: __ITextureShape, let isArray:int, let sampleCount:int, let format:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureLod(__TextureImpl< @@ -2649,7 +2650,7 @@ public float textureLod(sampler1DArrayShadow sampler, vec3 p, float lod) // textureOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureOffset(Sampler1D<vector<T,N>> sampler, float p, constexpr int offset, float bias = 0.0) @@ -2657,7 +2658,7 @@ public vector<T,4> textureOffset(Sampler1D<vector<T,N>> sampler, float p, conste return __vectorReshape<4>(sampler.SampleBias(p, bias, offset)); } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureOffset(Sampler2D<vector<T,N>> sampler, vec2 p, constexpr ivec2 offset, float bias = 0.0) @@ -2665,7 +2666,7 @@ public vector<T,4> textureOffset(Sampler2D<vector<T,N>> sampler, vec2 p, constex return __vectorReshape<4>(sampler.SampleBias(p, bias, offset)); } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureOffset(Sampler3D<vector<T,N>> sampler, vec3 p, constexpr ivec3 offset, float bias = 0.0) @@ -2739,7 +2740,7 @@ public float textureOffset(sampler1DShadow sampler, vec3 p, constexpr int offset } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureOffset(Sampler1DArray<vector<T,N>> sampler, vec2 p, constexpr int offset, float bias = 0.0) @@ -2747,7 +2748,7 @@ public vector<T,4> textureOffset(Sampler1DArray<vector<T,N>> sampler, vec2 p, co return __vectorReshape<4>(sampler.SampleBias(p, bias, offset)); } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureOffset(Sampler2DArray<vector<T,N>> sampler, vec3 p, constexpr ivec2 offset, float bias = 0.0) @@ -2918,7 +2919,7 @@ public vector<T,4> texelFetchOffset(Sampler2DRect<vector<T,N>> sampler, ivec2 p, // textureProjOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec2 p, constexpr int offset) @@ -2935,7 +2936,7 @@ public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec2 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec2 p, constexpr int offset, float bias) @@ -2952,7 +2953,7 @@ public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec2 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec4 p, constexpr int offset) @@ -2973,7 +2974,7 @@ public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec4 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec4 p, constexpr int offset, float bias) @@ -2994,7 +2995,7 @@ public vector<T,4> textureProjOffset(Sampler1D<vector<T,N>> sampler, vec4 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec3 p, constexpr ivec2 offset) @@ -3011,7 +3012,7 @@ public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec3 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec3 p, constexpr ivec2 offset, float bias) @@ -3028,7 +3029,7 @@ public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec3 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec4 p, constexpr ivec2 offset) @@ -3049,7 +3050,7 @@ public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec4 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec4 p, constexpr ivec2 offset, float bias) @@ -3070,7 +3071,7 @@ public vector<T,4> textureProjOffset(Sampler2D<vector<T,N>> sampler, vec4 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler3D<vector<T,N>> sampler, vec4 p, constexpr ivec3 offset) @@ -3087,7 +3088,7 @@ public vector<T,4> textureProjOffset(Sampler3D<vector<T,N>> sampler, vec4 p, con } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjOffset(Sampler3D<vector<T,N>> sampler, vec4 p, constexpr ivec3 offset, float bias) @@ -3192,7 +3193,7 @@ public float textureProjOffset(sampler2DShadow sampler, vec4 p, constexpr ivec2 // textureLodOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureLodOffset(Sampler1D<vector<T,N>> sampler, float p, float lod, constexpr int offset) @@ -3200,7 +3201,7 @@ public vector<T,4> textureLodOffset(Sampler1D<vector<T,N>> sampler, float p, flo return __vectorReshape<4>(sampler.SampleLevel(p, lod, offset)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureLodOffset(__TextureImpl< @@ -3282,7 +3283,7 @@ public float textureLodOffset(sampler1DArrayShadow sampler, vec3 p, float lod, c // textureProjLod // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLod(Sampler1D<vector<T,N>> sampler, vec2 p, float lod) @@ -3298,7 +3299,7 @@ public vector<T,4> textureProjLod(Sampler1D<vector<T,N>> sampler, vec2 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLod(Sampler1D<vector<T,N>> sampler, vec4 p, float lod) @@ -3318,7 +3319,7 @@ public vector<T,4> textureProjLod(Sampler1D<vector<T,N>> sampler, vec4 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLod(Sampler2D<vector<T,N>> sampler, vec3 p, float lod) @@ -3334,7 +3335,7 @@ public vector<T,4> textureProjLod(Sampler2D<vector<T,N>> sampler, vec3 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLod(Sampler2D<vector<T,N>> sampler, vec4 p, float lod) @@ -3354,7 +3355,7 @@ public vector<T,4> textureProjLod(Sampler2D<vector<T,N>> sampler, vec4 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_cuda_glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLod(Sampler3D<vector<T,N>> sampler, vec4 p, float lod) @@ -3414,7 +3415,7 @@ public float textureProjLod(sampler2DShadow sampler, vec4 p, float lod) // textureProjLodOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLodOffset(Sampler1D<vector<T,N>> sampler, vec2 p, float lod, constexpr int offset) @@ -3430,7 +3431,7 @@ public vector<T,4> textureProjLodOffset(Sampler1D<vector<T,N>> sampler, vec2 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLodOffset(Sampler1D<vector<T,N>> sampler, vec4 p, float lod, constexpr int offset) @@ -3450,7 +3451,7 @@ public vector<T,4> textureProjLodOffset(Sampler1D<vector<T,N>> sampler, vec4 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLodOffset(Sampler2D<vector<T,N>> sampler, vec3 p, float lod, constexpr ivec2 offset) @@ -3466,7 +3467,7 @@ public vector<T,4> textureProjLodOffset(Sampler2D<vector<T,N>> sampler, vec3 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLodOffset(Sampler2D<vector<T,N>> sampler, vec4 p, float lod, constexpr ivec2 offset) @@ -3486,7 +3487,7 @@ public vector<T,4> textureProjLodOffset(Sampler2D<vector<T,N>> sampler, vec4 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(glsl_hlsl_spirv, texture_sm_4_1_fragment)] public vector<T,4> textureProjLodOffset(Sampler3D<vector<T,N>> sampler, vec4 p, float lod, constexpr ivec3 offset) @@ -3547,7 +3548,7 @@ public float textureProjLodOffset(sampler2DShadow sampler, vec4 p, float lod, co // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureGrad(Sampler1D<vector<T,N>> sampler, float p, float dPdx, float dPdy) @@ -3555,7 +3556,7 @@ public vector<T,4> textureGrad(Sampler1D<vector<T,N>> sampler, float p, float dP return __vectorReshape<4>(sampler.SampleGrad(p, dPdx, dPdy)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureGrad(__TextureImpl< @@ -3662,7 +3663,7 @@ public float textureGrad(sampler2DArrayShadow sampler, vec4 p, vec2 dPdx, vec2 d // textureGradOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureGradOffset(Sampler1D<vector<T,N>> sampler, float p, float dPdx, float dPdy, constexpr int offset) @@ -3670,7 +3671,7 @@ public vector<T,4> textureGradOffset(Sampler1D<vector<T,N>> sampler, float p, fl return __vectorReshape<4>(sampler.SampleGrad(p, dPdx, dPdy, offset)); } -__generic<T:__BuiltinFloatingPointType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> +__generic<T:__BuiltinArithmeticType, let N:int, Shape:__ITextureShape, let isArray:int, let sampleCount:int, let format:int> [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] [ForceInline] public vector<T,4> textureGradOffset(__TextureImpl< @@ -3760,7 +3761,7 @@ public float textureGradOffset(sampler2DArrayShadow sampler, vec4 p, vec2 dPdx, // textureProjGrad // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGrad(Sampler1D<vector<T,N>> sampler, vec2 p, float dPdx, float dPdy) @@ -3776,7 +3777,7 @@ public vector<T,4> textureProjGrad(Sampler1D<vector<T,N>> sampler, vec2 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGrad(Sampler1D<vector<T,N>> sampler, vec4 p, float dPdx, float dPdy) @@ -3796,7 +3797,7 @@ public vector<T,4> textureProjGrad(Sampler1D<vector<T,N>> sampler, vec4 p, float } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGrad(Sampler2D<vector<T,N>> sampler, vec3 p, vec2 dPdx, vec2 dPdy) @@ -3812,7 +3813,7 @@ public vector<T,4> textureProjGrad(Sampler2D<vector<T,N>> sampler, vec3 p, vec2 } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGrad(Sampler2D<vector<T,N>> sampler, vec4 p, vec2 dPdx, vec2 dPdy) @@ -3832,7 +3833,7 @@ public vector<T,4> textureProjGrad(Sampler2D<vector<T,N>> sampler, vec4 p, vec2 } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGrad(Sampler3D<vector<T,N>> sampler, vec4 p, vec3 dPdx, vec3 dPdy) @@ -3892,7 +3893,7 @@ public float textureProjGrad(sampler2DShadow sampler, vec4 p, vec2 dPdx, vec2 dP // textureProjGradOffset // ------------------- -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGradOffset(Sampler1D<vector<T,N>> sampler, vec2 p, float dPdx, float dPdy, constexpr int offset) @@ -3908,7 +3909,7 @@ public vector<T,4> textureProjGradOffset(Sampler1D<vector<T,N>> sampler, vec2 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGradOffset(Sampler1D<vector<T,N>> sampler, vec4 p, float dPdx, float dPdy, constexpr int offset) @@ -3928,7 +3929,7 @@ public vector<T,4> textureProjGradOffset(Sampler1D<vector<T,N>> sampler, vec4 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGradOffset(Sampler2D<vector<T,N>> sampler, vec3 p, vec2 dPdx, vec2 dPdy, constexpr ivec2 offset) @@ -3944,7 +3945,7 @@ public vector<T,4> textureProjGradOffset(Sampler2D<vector<T,N>> sampler, vec3 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGradOffset(Sampler2D<vector<T,N>> sampler, vec4 p, vec2 dPdx, vec2 dPdy, constexpr ivec2 offset) @@ -3964,7 +3965,7 @@ public vector<T,4> textureProjGradOffset(Sampler2D<vector<T,N>> sampler, vec4 p, } } -__generic<T:__BuiltinFloatingPointType, let N:int> +__generic<T:__BuiltinArithmeticType, let N:int> [ForceInline] [require(cpp_glsl_hlsl_spirv, texture_sm_4_1)] public vector<T,4> textureProjGradOffset(Sampler3D<vector<T,N>> sampler, vec4 p, vec3 dPdx, vec3 dPdy, constexpr ivec3 offset) |
