Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > C++ > Help! How can I draw a bitmap only with BITMAP information!

Reply
Thread Tools

Help! How can I draw a bitmap only with BITMAP information!

 
 
xqggz
Guest
Posts: n/a
 
      06-19-2007
HI everyone,
Now I have only the information of the BITMAP , but not an actual
bitmap. I want to draw the bitmap according the BITMAP struction
information, what can I do? I use the VC2005 Express and I am not
familliar with the SDK function? I searched on the web site and got an
example as following, but it need load an actual bitmap resource. Now
I have only the bm:
case WM_PAINT:
{
BITMAP bm;
PAINTSTRUCT ps;

HDC hdc = BeginPaint(hwnd, &ps);

HDC hdcMem = CreateCompatibleDC(hdc);
HBITMAP hbmOld = SelectObject(hdcMem, g_hbmBall);

GetObject(g_hbmBall, sizeof(bm), &bm);

BitBlt(hdc, 0, 0, bm.bmWidth, bm.bmHeight, hdcMem, 0, 0,
SRCCOPY);

SelectObject(hdcMem, hbmOld);
DeleteDC(hdcMem);

EndPaint(hwnd, &ps);
}
break;
Could anybody help me??? Thanks!!!

 
Reply With Quote
 
 
 
 
Victor Bazarov
Guest
Posts: n/a
 
      06-19-2007
xqggz wrote:
> Now I have only the information of the BITMAP , but not an actual
> bitmap. I want to draw the bitmap according the BITMAP struction
> information, what can I do? [..]


This is not a C++ language question. Please ask in the newsgroup
dedicated to MS Windows programming. See FAQ for the list of the
suggested newsgroups.

V
--
Please remove capital 'A's when replying by e-mail
I do not respond to top-posted replies, please don't ask


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
How to draw a transparent bitmap by masking fancyerii Java 7 08-03-2008 05:19 AM
Re: How to draw a 1-bit or 4-bit Bitmap in java Lew Java 1 08-16-2007 11:22 PM
How to draw a 1-bit or 4-bit Bitmap in java Mukt Java 2 08-16-2007 10:46 PM
Masked bitmap from bitmap Gandalf Python 0 01-29-2004 09:41 PM



Advertisments