Sign in to follow this  
Boder

[.net] Playing with PictureBox's Bits

Recommended Posts

I read some good advices from the Cap'n and Mr. Ryves, including bypassing the PictureBox control altogether and using LockBits(). But if I am using a picturebox control, is there a way to manipulate the pixels of the PictureBox.Image without creating a new Bitmap every time (and setting it back, whatever that entails)? I know I can create a Graphics object, but it doesn't expose the naughty bits. So what am I missing?

Share this post


Link to post
Share on other sites
If you have a Bitmap and assign it to a PictureBox's Image property, you can make a change to the bitmap and simply call the PictureBox's Invalidate method to update the image.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this