Picturebox+Image

Asked

Viewed 156 times

0

I have a Picturebox1 with an image (cameras-Hdv-Merlin-courses.png) example:

private void pictureBox1_Click(object sender, EventArgs e)
        {

        }

When you hover your mouse over it I’d like it to have a zoom effect,.

How can I do that?

1 answer

1


The effect itself is a little complicated, but in this link you already have access to the very detailed source code of how to implement. In this link also has another example.

You can also consider creating a new bitmap instance:

Size newSize = new Size((int)(originalBitmap.Width * zoomFactor), (int)(originalBitmap.Height * zoomFactor));
Bitmap bmp = new Bitmap(originalBitmap, newSize);

Just follow the following links you will get.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.