It's a bad idea to use redundant and primitive control
PictureBox
if you do something except showing static images. This is some intermediary (control, not image) which only wastes your working time and some extra resource, without giving any benefits in return. If you need to zoom, better render image directly on your own custom control, or some existing control like
Panel
. Please see my past answers:
Append a picture within picturebox[
^],
How do I clear a panel from old drawing[
^],
draw a rectangle in C#[
^].
And these answers on graphics rendering:
What kind of playful method is Paint? (DataGridViewImageCell.Paint(...))[
^],
capture the drawing on a panel[
^],
Drawing Lines between mdi child forms[
^],
specifically on zoom:
Zoom image in C# .net mouse wheel[
^].
Also, if you plan to zoom in some bitmap image (that is, enlarging it above its original size in pixels), it also would be a bad idea, because you will get prohibitively poor quality. If you really need so, always provide original image with the size equal or just a bit smaller then the maximum zoom size. Better yet, resort to vector graphics, if it's possible.
—SA