aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/sksl/sksl_fp.include
blob: 0d8d99d7b850347503365820c8fd29e401b7e430 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
STRINGIFY(

// defines built-in interfaces supported by SkiaSL fragment shaders

layout(builtin=15) in vec4 sk_FragCoord;
layout(builtin=3) float sk_ClipDistance[1];

// 9999 is a temporary value that causes us to ignore these declarations beyond
// adding them to the symbol table. This works fine in GLSL (where they do not
// require any further handling) but will fail in SPIR-V. We'll have a better
// solution for this soon.
layout(builtin=9999) vec4 gl_LastFragData[1];
layout(builtin=9999) vec4 gl_LastFragColor;
layout(builtin=9999) vec4 gl_LastFragColorARM;
layout(builtin=9999) int gl_SampleMaskIn[1];
layout(builtin=9999) out int gl_SampleMask[1];
layout(builtin=9999) vec4 gl_SecondaryFragColorEXT;

layout(builtin=10003) vec4 sk_InColor;
layout(builtin=10004) out vec4 sk_OutColor;
layout(builtin=10005) vec2[] sk_TransformedCoords2D;
layout(builtin=10006) sampler2D[] sk_TextureSamplers;

vec4 COLORSPACE(vec4 color, colorSpaceXform colorSpace);
)