Sign in to follow this  
b1gjo3

BitBlt Problem

Recommended Posts

b1gjo3    213
hi everyone, im trying to draw a bitmap to my window and i have successfully done so when the image is less than about 2500 pixels. For some reason i cannot draw larger images, why might this be? Should i just limit BitBlt to draw a region of the bitmap instead of trying to draw it all at once. My goal is to be able to draw a bitmap that is at least 5000 pixels in size. thank you

Share this post


Link to post
Share on other sites
Colin Jeanne    1114
BitBlt() shouldnt have a problem with very large bitmaps but that said, why not just draw the visible portion of the bitmap?

Also, when BitBlt() fails you can use GetLastError() to find out why.

Share this post


Link to post
Share on other sites
b1gjo3    213
how can i view the results of GetLastError()? Ive tried messagebox but it doesnt work.

i eventually plan on making a picturebox like VB with 2 scroll bars (horiz, vert)
to display an image. for some reason i can only disp images with less than 2000 pixels in dimensions

Share this post


Link to post
Share on other sites
b1gjo3    213
i found the problem

CopyImage() fails on windows vista with an image that has a width greater than 2047 pixels.

here is a link for more details
http://support.microsoft.com/kb/935607

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