Skip to main content
gamedev.net
🔒 Locked

I need Help!!

Started by anakin_skywalker May 13, 2003 at 9:57 PM 1 replies 250+ views
Original Post
anakin_skywalker
anakin_skywalker
Hi everyone, I would like to know if someone could help me with this. First, I am using c++. I store a 256 colors bitmap as a resource in my .exe file, and I called mySprite. I create a handle to this bitmap like this: HBITMAP hbitmap; if(!(hbitmap = (HBITMAP)LoadImage globalInstance,MAKEINTRESOURCE(mySprite),IMAGE_BITMAP,0,0,LR_CREATEDIBSECTION))) return 0; Furthermore, I created an array of PALETEENTRY''s to store the palette of this bitmap...but, i don''t know how to do it. Can anybody tell me how to extract the palette from this bitmap resource,and store it into the array of PALETTEENTRY''s. Thanks!!
Dave Hunt
Dave Hunt
Select the bitmap into a device context, then call GetDIBColorTable to retrieve the color table values.

GetDIBColorTable

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.