B
Bartek Tatkowski
I currently developing an application (in C#) where I have to be able to
highlight different regions on the screen, by drawing a half-transparent
ellipse over it. Right now, the code I'm using is this:
// Get the Graphics object of the entire screen.
IntPtr dc1 = Utils.CreateDC("DISPLAY", null, null, (IntPtr)null);
Graphics g1 = Graphics.FromHdc(dc1);
// Draw filled ellipse
SolidBrush brush = new SolidBrush(Color.FromArgb(128, 0, 255, 0));
g1.FillEllipse(brush, x, y, w, h);
g1.Flush();
The problem with this is that I have no means of erasing what I have drawn.
Is there any way to draw on another "layer", so that the different windows I
draw on don't get draw on?
highlight different regions on the screen, by drawing a half-transparent
ellipse over it. Right now, the code I'm using is this:
// Get the Graphics object of the entire screen.
IntPtr dc1 = Utils.CreateDC("DISPLAY", null, null, (IntPtr)null);
Graphics g1 = Graphics.FromHdc(dc1);
// Draw filled ellipse
SolidBrush brush = new SolidBrush(Color.FromArgb(128, 0, 255, 0));
g1.FillEllipse(brush, x, y, w, h);
g1.Flush();
The problem with this is that I have no means of erasing what I have drawn.
Is there any way to draw on another "layer", so that the different windows I
draw on don't get draw on?