Re: Simulate Autoredraw
- From: Dennis <Dennis@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 27 Sep 2006 16:12:02 -0700
Use whatever you want. I personally use the bitblt and it's ligntning
quick. I would think that an image has to be rendered during each paint
event from a general format and copied to the picturebox or whatever. In VB6
and before, I think controls had the option of having their background
persistent in memory and didn't have to be redarwn to the picturebox, etc.
each time it was repainted. However, in VB.Net this changed so the image has
to be copied to the picturebox during each paint event.
--
Dennis in Houston
"Doug Marquardt" wrote:
Hi Dennis:.
Pardon my ignorance here...
but I really don't see how bitblt in the paint event
could be quicker than assigning the bitmap
to the image -- the point being that once I assign
the image the control takes over all the painting, etc.???
Just curious...
Doug.
"Dennis" <Dennis@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:62E328B6-D10B-406B-AE2A-A233D041A012@xxxxxxxxxxxxxxxx
I think it may be a bit quicker.graphics
--
Dennis in Houston
"Doug Marquardt" wrote:
Hi Dennis:
I was able to figure out to create the graphics from the bitmap,
and was able to draw to it, etc.
Assigning the bitmap to the image property seems to work fine...
what advantages would there be to bitblt in the paint event?
Doug.
"Doug Marquardt" <no_spam@xxxxxxxxx> wrote in message
news:%23IgjOtQ4GHA.3444@xxxxxxxxxxxxxxxxxxxxxxx
Hi Dennis:
That was the first thing I looked at, but I couldn't
figure out how to draw to the bitmap (the only
method I saw was for setting pixels).
So how do you draw to the bitmap?
Doug.
"Dennis" <Dennis@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:4CEAC020-1D11-4686-937B-280B6AAF7009@xxxxxxxxxxxxxxxx
Just create a bitmap that's persistent. You can then create a
useobject from it and draw on the bitmap. In the paint event, you can
havebitblt to copy the bitmap to your form, picture box, or whatever. I
an
example if you like.
--
Dennis in Houston
"Doug Marquardt" wrote:
Hi All:
I want to simulate VB6 Autoredraw in VB.Net
I figure I would probably have to create a memory dc,
paint to that, and then create a bitmap based on the dc
and copy that image into a bitmap,
and then assign that to the image property of my control?
If so, then can someone push me in the right direction
to get started on this.
If not, then what would you suggest.
Thanks.
Doug.
- References:
- Simulate Autoredraw
- From: Doug Marquardt
- Re: Simulate Autoredraw
- From: Doug Marquardt
- Re: Simulate Autoredraw
- From: Doug Marquardt
- Re: Simulate Autoredraw
- From: Dennis
- Re: Simulate Autoredraw
- From: Doug Marquardt
- Simulate Autoredraw
- Prev by Date: Re: Bug in Datagrids
- Next by Date: Ftp Client Help
- Previous by thread: Re: Simulate Autoredraw
- Next by thread: cross Thread not valid
- Index(es):
Relevant Pages
|