Page 1 of 1

How to fill a BITMAPINFO structure?

Posted: Wed Dec 01, 2004 11:46 pm
by mojo
Hi,

How can I fill a BITMAPINFO structure from an image loaded with your already insane cool library? ;) What im trying todo is to use the function "StretchDIBits", wich requires a filled BITMAPINFO structure. I have looked at one of the examples in "\GflSDK\win32\example.c", function "GetDIBFromBitmap". This seems simple enough, but i noticed alot of code wich was removed by comments. But if that example is good enough for loading all types of images then ill use that one in my code.

There is nothing else to say then that i am a totally noob when it comes to this type of stuff. So treat me like one when you reply. :) And that you'r library is truly awesome! Nothin like iv'e ever encountererd. :)


Thanks in advance for any suggestions, mojo

Re: How to fill a BITMAPINFO structure?

Posted: Thu Dec 02, 2004 7:18 am
by xnview
mojo wrote:Hi,

How can I fill a BITMAPINFO structure from an image loaded with your already insane cool library? ;) What im trying todo is to use the function "StretchDIBits", wich requires a filled BITMAPINFO structure. I have looked at one of the examples in "\GflSDK\win32\example.c", function "GetDIBFromBitmap". This seems simple enough, but i noticed alot of code wich was removed by comments. But if that example is good enough for loading all types of images then ill use that one in my code.

There is nothing else to say then that i am a totally noob when it comes to this type of stuff. So treat me like one when you reply. :) And that you'r library is truly awesome! Nothin like iv'e ever encountererd. :)


Thanks in advance for any suggestions, mojo
With GetDIBFromBitmap, you have a good example how to convert GFL_BITMAP to a DIBHEADER

Posted: Thu Dec 02, 2004 11:25 am
by mojo
Thanks for the information. Then i'll just proceed with converting that example. :D