Search code examples
c++windowsgdi+gdi

What's the equivalent of PolyDraw function in GDI+?


I can use PolyDraw function to draw a continuous custom line segment. But what is the equivalent to that function if I'm using GDI+?


Solution

  • The closest is GraphicsPath, which stores a group of (possibly) disjoint paths which can be passed to Graphics::DrawPath to be drawn in one call.

    See reference.

    Graphics::FillPath will fill any closed paths you have.