There is a method for drawing object outlines in OpenGL by setting
backfacing polygons to be rendered with lines and overriding the backface
color to the desired outline color.  I am trying to apply this method to
models loaded from a file into a scenegraph.  The first step is easy
enough: obtain the model's StateSet and apply a PolygonMode( BACK, LINE )
StateAttribute.  However, I cannot find an obvious way to override the
polygon back face color, short of either directly editing the loaded model
file or applying a vertex and fragment shader.  Is there something simple I
am missing?

Additionally, when the PolygonMode attribute is set as above, I see warning
messages as follows:

Warning: detected OpenGL error 'invalid enumerant' after RenderBin::draw(,)

Is there something I need to do to avoid this error?  It doesn't seem to
adversely affect rendering.
- Ian Zeilstra




This is an e-mail from General Dynamics Land Systems. It is for the intended 
recipient only and may contain confidential and privileged information.  No one 
else may read, print, store, copy, forward or act in reliance on it or its 
attachments.  If you are not the intended recipient, please return this message 
to the sender and delete the message and any attachments from your computer. 
Your cooperation is appreciated.

_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to