Question: Building a little paint program and am trying to incorporate the concept of layers.

I'm using a PictureBox control to display the image, and getting the Graphics object from the image being displayed by the PictureBox and drawing to that.

My problem is I'm trying to figure out how to draw to a new Graphics object that is overlayed on top of the picture box, and be able to get the newly drawn image *without* the original image absorbed into the graphic.

If I do something like:

```
Graphics gr = Graphics.FromImage(myPictureBox.image);
gr.DrawRectangle(blah blah)

```

...I am editing the original image in the picture box. I want a way to only capture the new stuff being drawn as a separate image, but still have it displayed as an overlay over top of what was already there.

Anyone able to point me in the right direction? Thanks!

Answer: 
Got it working, perhaps I wasn't clear enough in my original question.

Essentially what I ended up doing was storing each layer as a separate Image object, then just hooking into the OnPaint method of my control and manually drawing the graphics in order, instead of just drawing to PictureBox.Image. Works like a charm!
The graphics capabilities of .NET drawing libraries are simple. Their main purpose is direct drawing of GUI. If you want to have layering, alpha transparency or advanced filters, then you should either use 3rd party library or roll your own drawing code.