The QPainter::drawConvexPolygon()
documentation says:
On some platforms (e.g. X11), the drawConvexPolygon() function can be faster than the drawPolygon() function.
So,
drawPolygon()
is more generic as it also allows to paint non-convex polygons (but drawing might be slower)drawConvexPolygon()
can only be used to draw convex polygons, but might be faster on specific platforms
For example, when doing 3D-rendering, you can use a Polygon Mesh which consists of convex polygons only to make rendering simpler, in which case the faster drawConvexPolygon()
would be the better choice (since you need to paint a large number of convex polygons).