|
-
Jun 14th, 2002, 07:21 AM
#1
Thread Starter
Member
BitBlt
I am new with VB and I have been trying to stop my images from flickering with minimal success. I came across a program using the bitblt API but I can't understand what is done for the life of me. Would anyone mind looking at this sample code and comment the lines or something to make it a little easier to understand?
BitBlt Animation
Thank you so much!
-
Jun 14th, 2002, 07:36 AM
#2
Lively Member
Actually if you are stumped with bitblt try paintpicture. Its almost the same thing.
Object.paintpicutre object.hdc,x1,y1,width1,height1,x2,y2,width2,height2,raster
'set autoredraw to true and that should get rid of your flicker
I program in: vb6,vb.net,html,c++,java/script
-
Jun 14th, 2002, 07:44 AM
#3
Thread Starter
Member
Would you mid telling me what hdc does? In the above program I used a message box and noticed it is always a negative number in the millions but it is random... If it is random then what's it do?
-
Jun 14th, 2002, 08:00 AM
#4
Member
Why do you say it's random? It simply isn't! hDC is the DC (Device Context) of a picture, you can think of it as a number that allows you to access the picture that is stored somewhere in your memory. You need the DC for any function like BitBlt, TextOut, SetPixel and such.
-
Jun 14th, 2002, 08:00 AM
#5
Hyperactive Member
HDC is basically where you want the image to go
in this case, it's the Picturebox..
the HDC is sort of like the picture property...
-
Jun 16th, 2002, 04:01 PM
#6
Frenzied Member
Sorry, I know it's a silly question, but you can use DCs for printers and all... is it really just an image like regular DCs, or can be used for other stuff? No one ever explained that to me, the tutorial I read said "it's kinda like a pointer to the image" and after that I got into DX but now I'm curious
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
|