1STRINGIFY(
2
3// defines built-in interfaces supported by SkiaSL fragment shaders
4
5layout(builtin=15) in float4 sk_FragCoord;
6layout(builtin=3) float sk_ClipDistance[1];
7layout(builtin=20) out int sk_SampleMask[1];
8
9// 9999 is a temporary value that causes us to ignore these declarations beyond
10// adding them to the symbol table. This works fine in GLSL (where they do not
11// require any further handling) but will fail in SPIR-V. We'll have a better
12// solution for this soon.
13layout(builtin=9999) float4 gl_LastFragData[1];
14layout(builtin=9999) half4 gl_LastFragColor;
15layout(builtin=9999) half4 gl_LastFragColorARM;
16layout(builtin=9999) half4 gl_SecondaryFragColorEXT;
17
18layout(builtin=10003) half4 sk_InColor;
19layout(builtin=10004) out half4 sk_OutColor;
20layout(builtin=10005) float2[] sk_TransformedCoords2D;
21layout(builtin=10006) sampler2D[] sk_TextureSamplers;
22layout(builtin=10011) half sk_Width;
23layout(builtin=10012) half sk_Height;
24
25half4 sample(fragmentProcessor fp);
26half4 sample(fragmentProcessor fp, float2 coords);
27half4 sample(fragmentProcessor fp, half4 input);
28half4 sample(fragmentProcessor fp, half4 input, float2 coords);
29half4 sample(fragmentProcessor? fp);
30half4 sample(fragmentProcessor? fp, float2 coords);
31half4 sample(fragmentProcessor? fp, half4 input);
32half4 sample(fragmentProcessor? fp, half4 input, float2 coords);
33)
34