• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#version 450
2
3in float if1;
4in vec2  if2;
5in vec3  if3;
6in vec4  if4;
7
8flat in int samp;
9flat in vec2 offset;
10
11out vec4 fragColor;
12
13void main()
14{
15    vec4 f4 = vec4(0.0);
16    f4.x    += interpolateAtCentroid(if1);
17    f4.xy   += interpolateAtCentroid(if2);
18    f4.xyz  += interpolateAtCentroid(if3);
19    f4      += interpolateAtCentroid(if4);
20
21    f4.x    += interpolateAtSample(if1, samp);
22    f4.xy   += interpolateAtSample(if2, samp);
23    f4.xyz  += interpolateAtSample(if3, samp);
24    f4      += interpolateAtSample(if4, samp);
25
26    f4.x    += interpolateAtOffset(if1, offset);
27    f4.xy   += interpolateAtOffset(if2, offset);
28    f4.xyz  += interpolateAtOffset(if3, offset);
29    f4      += interpolateAtOffset(if4, offset);
30
31    fragColor = f4;
32}
33