xref: /aosp_15_r20/external/angle/third_party/glslang/src/Test/spv.fragmentShaderBarycentric4.frag (revision 8975f5c5ed3d1c378011245431ada316dfb6f244)
1#version 320 es
2#extension GL_EXT_fragment_shader_barycentric : require
3
4precision highp float;
5
6layout(location = 0) pervertexEXT in float vertexIDs[3];
7layout(location = 1) pervertexEXT in float vertexIDs2[3];
8
9layout(location = 1) out float value;
10
11void main () {
12    value = (gl_BaryCoordNoPerspEXT.x * vertexIDs[0] +
13             gl_BaryCoordNoPerspEXT.y * vertexIDs[1] +
14             gl_BaryCoordNoPerspEXT.z * vertexIDs[2]);
15
16    value += (gl_BaryCoordNoPerspEXT.x * vertexIDs2[0] +
17             gl_BaryCoordNoPerspEXT.y * vertexIDs2[1] +
18             gl_BaryCoordNoPerspEXT.z * vertexIDs2[2]);
19
20}
21