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