Draw an arrow (or line) representing a direction.

Hello!

As the subject states, I would like to render an arrow or a simple line that allows me to visually see a direction (vector).

For example, to render the incoming light direction, view direction, or surface normals.

If this can be done on GLSL that would be awesome!

Thx

bump.


glBegin (GL_LINES);
glVertex3fv (pos);
glVertex3f (pos.x+dir.x, pos.y+dir.y, pos.z+dir.z);
glEnd()