Hello,
This may be a simple question. I'm trying to draw a path with multiple
polygons and circles. Transparency is set to 50%. I want the overlap
regions NOT to show. That is, they should be the same transparency level and
color as the non-overlap regions. Is there any way to do this? I keep
getting situations where the overlaps are darker, or not displayed at all.
Below is some sample code.
Color c = Color.FromArgb(50, Color.Blue);
SolidBrush b = new SolidBrush(c);
Point[] polygon = new Point[3]
{
new Point(50,50),
new Point(50,200),
new Point(150,150),
}
GraphicsPath path = new GraphicsPath();
path.addEllipse(new Rectangle(100,100,100,100));
path.addPolygon(polygon);
g.FillPath(b, path);
This code draws the polygon and the circle, but the overlapped region is not
drawn. If I draw two paths, then the overlap region is too dark. I've also
tried setting the FillMode to Winding, but that only helps if all my shapes
are circles.