How to fill an 2D object?

Mar 12, 2013 at 6:00 PM
Hello everyone, I'm a newbie in programming, I drew a 2D object for example a Rectangle, by using "vertex" command. I don't know how to fill it. Could someone help me? :((
By the way, is there any simple way to draw circle, triangle? :-ss
Mar 14, 2013 at 4:05 PM
To fill a rectangle, make sure that you draw in 'polygon' mode, rather than lines or points. If lighting is not enabled, glColor will set the color, otherwise the glLightParam functions can be used to configure the lights and glMaterial for the material - or just use the SharpGL objects 'Light' and 'Material' to do the hard work for you :)
Mar 15, 2013 at 2:55 AM
Edited Mar 15, 2013 at 2:56 AM
Thank you so much, but could you please give me an example? 'Cos I'm not good in using OpenGL. :">
Mar 17, 2013 at 5:01 PM has an example of rendering solid color geometry, triangles as well
Mar 18, 2013 at 9:45 AM
Thank you so much. :)