|
-
Nov 26th, 2000, 08:14 PM
#1
Thread Starter
Hyperactive Member
Hey, i have a picturebox, and i am constantly Painting Pictures
( Picture1.paintpicture )
I was wondering.
if i CLEAR what is on the picturebox, before re-painting..
would it save RAM? or memory?
And how would i go about doing this to only a few pixels
cause i have
many squares
16x16.. is one square
and i have many squares..
so how would i CLEAR one square that i select?
-
Nov 27th, 2000, 05:26 AM
#2
Addicted Member
No, it does not save on resources to clear the picture.
Each picturebox has two graphic areas. The picture property is where the permanent picture resides. The Image property is where your drawings reside.
What this means is that if you set the picture property of the box, a copy is also placed in the image property. If you now draw on the picture, you are drawing on the image property. If you "clear" the picture, the picture property is copied over the image property, and you lose your changes. So the Image property will ALWAYS have a picture in it, whether you clear it or not.
Shrog
-
Nov 27th, 2000, 04:18 PM
#3
Thread Starter
Hyperactive Member
Ohhh, thanks for the input.
Lastly, how would i check the picturebox to see if a pixel has been cleared (if the auto redraw is FALSE, and u open another program over it, the image is cleared)
Insted of setting it true, is there a way to check if a pixel is CLEARED?
thanks thanks
-
Nov 27th, 2000, 05:06 PM
#4
Addicted Member
No, pixels don't work that way. When you read the pixel from the picture, it returns the color of that pixel. You cannot tell if it was a different color a few moments ago - it just returns the color that it is at the moment of reading it.
Shrog
[Edited by Shrog on 11-27-2000 at 05:08 PM]
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|