Tengo 4 Elipses graficadas y necesito intersectarlas una vez mas para continuar con los diagramas de Venn que he venido publicando, la situacion es la siguiente tengo 2 elipses inclinadas a 25 grados que se interctan entre si y tambien se intersectan con 2 elipses inclinadas a -25 grados, el problema en esta ocasion es que a pesar de que a vista del ojo se intersectan las 4 elipses solo puedo intersectar dentro del codigo las elipses que poseen el mismo grado de inclinacion, a continuacion les dejo el codigo para ver si me pueden nuevamente hechar una mano. Gracias.
/*********************Dibujo Elipse 1 *********************/
Singleton.Instance.progresoVenn.Value = 100;
int ancho = Singleton.Instance.panelVenn.ClientRectangle.Heigh t ;
int alto = Singleton.Instance.panelVenn.ClientRectangle.Heigh t / 3;
int posX1 = Singleton.Instance.panelVenn.ClientRectangle.Width / 6;
int posY1 = Singleton.Instance.panelVenn.ClientRectangle.Heigh t / 20;
Rectangle R1 = new Rectangle(posX1, posY1, ancho, alto);
// Create a Graphics object
Graphics G = Singleton.Instance.panelVenn.CreateGraphics() ;
// Create a Matrix object
Matrix X = new Matrix();
// Rotate by 45 degrees
X.Rotate(25, MatrixOrder.Append);
// Apply Matrix object to the Graphics object
// (i.e., to all the graphics items
// drawn on the Graphics object)
G.Transform = X;
// Fill a rectangle
GraphicsPath P1 = new GraphicsPath();
P1.AddEllipse(R1);
G.FillEllipse(Brushes.Blue, R1);
G.DrawPath(Pens.Black, P1);
/*********************Dibujo Elipse 2 *********************/
int posX2 = Singleton.Instance.panelVenn.ClientRectangle.Width / 7;
int posY2 = Singleton.Instance.panelVenn.ClientRectangle.Heigh t / 5;
Rectangle R2 = new Rectangle(posX2, posY2, ancho, alto);
// Create a Matrix object
Matrix X2 = new Matrix();
// Rotate by 45 degrees
X2.Rotate(25, MatrixOrder.Append);
// Apply Matrix object to the Graphics object
// (i.e., to all the graphics items
// drawn on the Graphics object)
G.Transform = X2;
// Fill a rectangle
GraphicsPath P2 = new GraphicsPath();
P2.AddEllipse(R2);
G.FillEllipse(Brushes.Red, R2);
G.DrawPath(Pens.Black, P2);
G.SetClip(P1);
G.SetClip(P2, CombineMode.Intersect);
G.FillEllipse(Brushes.YellowGreen, R1);
/*********************Dibujo Elipse 3 *********************/
int posX3 = Singleton.Instance.panelVenn.ClientRectangle.Width / -12;
int posY3 = Singleton.Instance.panelVenn.ClientRectangle.Heigh t / 3;
Rectangle R3 = new Rectangle(posX3, posY3, ancho, alto);
// Create a Matrix object
Matrix X3 = new Matrix();
// Rotate by 45 degrees
X3.Rotate(-25, MatrixOrder.Append);
// Apply Matrix object to the Graphics object
// (i.e., to all the graphics items
// drawn on the Graphics object)
G.Transform = X3;
// Fill a rectangle
GraphicsPath P3 = new GraphicsPath();
P3.AddEllipse(R3);
G.SetClip(P3);
G.FillEllipse(Brushes.Yellow, R3);
G.DrawPath(Pens.Black, P3);
/*********************Dibujo Elipse 4 *********************/
int posX4 = Singleton.Instance.panelVenn.ClientRectangle.Width / -16;
int posY4 = Singleton.Instance.panelVenn.ClientRectangle.Heigh t / 2;
Rectangle R4 = new Rectangle(posX4, posY4, ancho, alto);
// Create a Matrix object
Matrix X4 = new Matrix();
// Rotate by 45 degrees
X4.Rotate(-25, MatrixOrder.Append);
// Apply Matrix object to the Graphics object
// (i.e., to all the graphics items
// drawn on the Graphics object)
G.Transform = X4;
// Fill a rectangle
GraphicsPath P4 = new GraphicsPath();
P4.AddEllipse(R4);
G.SetClip(P4);
G.FillEllipse(Brushes.Green, R4);
G.DrawPath(Pens.Black, P4);
G.SetClip(P3);
G.SetClip(P4, CombineMode.Intersect);
G.FillEllipse(Brushes.Firebrick, R3);
G.SetClip(P3);
G.SetClip(P2, CombineMode.Intersect);
G.FillEllipse(Brushes.DimGray, R3);