title: What is the GLSL equivalent of gl_PointCoord for LINES?
body: <p>So, in OpenGLES-2 the fragment shader has access to <strong>gl_PointCoord</strong> to see where the fragment is located on a point primitive.</p>
  
  <p>There is also <strong>gl_FragCoord</strong> to see where a fragment is located on the frame buffer.</p>
  
  <p>However, where is <strong>gl_LineCoord</strong>?
  It does not exist, so how can my fragment shader know the location of a fragment on a line primitive?</p>
  
  <p>The reason I want to know this, is that I want to do a dashed line, with the dashes in screen space, not world space.</p>
  
  <p>The only way to do this that I can currently think of is taking a sqrt of fragCoord.x^2 + fragCoord.y^2 but that sounds costly and unnecessary if there only was a gl_LineCoord available.</p>