Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

16 řádky
539 B

  1. #version 330
  2. // Input uniform values
  3. uniform vec4 color;
  4. // Output fragment color
  5. out vec4 finalColor;
  6. // NOTE: Add here your custom variables
  7. void main()
  8. {
  9. // Each point is drawn as a screen space square of gl_PointSize size. gl_PointCoord contains where we are inside of
  10. // it. (0, 0) is the top left, (1, 1) the bottom right corner.
  11. // Draw each point as a colored circle with alpha 1.0 in the center and 0.0 at the outer edges.
  12. finalColor = vec4(color.rgb, color.a * (1 - length(gl_PointCoord.xy - vec2(0.5))*2));
  13. }