blob: e96165be1fcf42a0eeff307187bc3e7f090552f9 [file] [log] [blame]
ethannicholasb3058bd2016-07-01 08:22:01 -07001STRINGIFY(
2
3// defines built-in interfaces supported by SkiaSL fragment shaders
4
Ethan Nicholas8aa45692017-09-20 11:24:15 -04005layout(builtin=15) in float4 sk_FragCoord;
6layout(builtin=3) float sk_ClipDistance[1];
ethannicholasb3058bd2016-07-01 08:22:01 -07007
ethannicholas5961bc92016-10-12 06:39:56 -07008// 9999 is a temporary value that causes us to ignore these declarations beyond
9// adding them to the symbol table. This works fine in GLSL (where they do not
10// require any further handling) but will fail in SPIR-V. We'll have a better
11// solution for this soon.
Ethan Nicholas8aa45692017-09-20 11:24:15 -040012layout(builtin=9999) float4 gl_LastFragData[1];
Ethan Nicholasf7b88202017-09-18 14:10:39 -040013layout(builtin=9999) half4 gl_LastFragColor;
14layout(builtin=9999) half4 gl_LastFragColorARM;
Ben Wagnerd9fcb232016-11-04 13:07:29 -040015layout(builtin=9999) int gl_SampleMaskIn[1];
16layout(builtin=9999) out int gl_SampleMask[1];
Ethan Nicholasf7b88202017-09-18 14:10:39 -040017layout(builtin=9999) out half4 gl_SecondaryFragColorEXT;
jvanverth9df16b52016-10-11 10:03:56 -070018
Ethan Nicholasf7b88202017-09-18 14:10:39 -040019layout(location=0,index=0,builtin=10001) out half4 sk_FragColor;
ethannicholas5961bc92016-10-12 06:39:56 -070020
21)