Outlining Objects in OpenGL

Started by
0 comments, last by PGmeiner 22 years, 9 months ago
I woiuld display some Obejcts for example a simple Cube who is filled with a color (drawed in Mode GL_FILLED) and whos edges are drawn as black lines. I will outline the cube. Exists there a another possibilty to do this instead of drawing the filled cube first and overdraw it with black lines ?? Thanks for your help Peter Gmeiner
Peter Gmeiner
Advertisement
no i think thats the easiest way
glPolygonMode( GL_FRONT, GL_FILL )
draw cube
glPolygonMode( GL_FRONT, GL_LINE )
draw cube // the vertices should still be in hardware thus this shouldnt be so slow

perhaps also for the line version u need glDepthFunc( GL_EQUAL ) or glPolygonOffSet(..)

This topic is closed to new replies.

Advertisement