glBegin(GL_TRIANGLES);
glColor3f(0.1, 0.2, 0.3);
glVertex3f(0, 0, 0);
glVertex3f(1, 0, 0);
glVertex3f(0, 1, 0);
glEnd();
- This gives you unlit, untextured, flat-shaded triangles
- You can also draw triangle strips, quadrilaterals, and general polygons by
changing what value you pass to glBegin