Results 1 to 3 of 3

Thread: GetBitmapBits() **Resolved**

  1. #1

    Thread Starter
    Addicted Member jmiller's Avatar
    Join Date
    Jul 2002
    Location
    University of Michigan
    Posts
    238

    GetBitmapBits() **Resolved**

    I need to use GetBitmapBits(), but the function requires that you pass it an HBITMAP structure as the bitmap's handle. This is a problem if you create the bitmap using load image. LoadImage returns a HANDLE structure as the bitmaps handle. How do i get around this?

    thanks,
    jmiller
    Last edited by jmiller; Feb 25th, 2003 at 07:12 PM.

  2. #2
    Kitten CornedBee's Avatar
    Join Date
    Aug 2001
    Location
    In a microchip!
    Posts
    11,594
    Explicitly cast it:
    C++
    HBITMAP hbm = reinterpret_cast<HBITMAP>(handle);
    C
    HBITMAP hbm = (HBITMAP)handle;
    All the buzzt
    CornedBee

    "Writing specifications is like writing a novel. Writing code is like writing poetry."
    - Anonymous, published by Raymond Chen

    Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.

  3. #3

    Thread Starter
    Addicted Member jmiller's Avatar
    Join Date
    Jul 2002
    Location
    University of Michigan
    Posts
    238
    thanks a bunch! it works great

    jmiller

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width