If you’re using OpenGL, you may have a need to triangulate your polygons in order to draw them.

A common algorithm to do this is the ear clipping algorithm. We’ve been on the search for a solid implementation of this for a while, and have finally found one:

http://www.flipcode.com/archives/Efficient_Polygon_Triangulation.shtml

It’s written in c++ and has no dependencies (except for stl). It was really easy to use, and worked well in our tests.