PDA

View Full Version : xz-plane Grid



mahmad
03-22-2015, 11:47 AM
I need some guidance on how i should draw a grid in opengl . I am using programmable pipeline

1685

Agent D
03-23-2015, 03:40 AM
Simple: Draw a bunch of lines. Similar to drawing triangles, except you use the GL_LINES mode instead of GL_TRIANGLES.

Use a simple vertex shader that only applies a transformation and a fragment shader that emits a constant color.

mahmad
03-23-2015, 07:32 AM
Thanks. I made it.1688