Thread: bitmap pixels???????????

  1. #1
    Registered User
    Join Date
    Sep 2001
    Posts
    173

    Unhappy bitmap pixels???????????

    Hi

    If I know bitmap pixels' value e.g(RGB), how can I attach them with the function CreateBitmap()

    Code:
    HBITMAP CreateBitmap(
      int nWidth,         // bitmap width, in pixels
      int nHeight,        // bitmap height, in pixels
      UINT cPlanes,       // number of color planes
      UINT cBitsPerPel,   // number of bits to identify color
      CONST VOID *lpvBits // color data array
    );
    I don't know how can I build such relationship between lpvBits and my pixels' value or is there any other way out? Thanks for the help.
    Don't laugh at me,I am just a SuperNewbie.

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,981
    Read/Study this article: DIBs and Their Use.

    gg

  3. #3
    Registered User
    Join Date
    Sep 2001
    Posts
    173
    Thanks, I've read through this article before, but I don't have any idea about this, can you make any simple example in case of my question? Thanks
    Don't laugh at me,I am just a SuperNewbie.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Loading a bitmap (Without using glaux)
    By Shamino in forum Game Programming
    Replies: 7
    Last Post: 03-16-2006, 09:43 AM
  2. OpenGL -- Bitmaps
    By HQSneaker in forum Game Programming
    Replies: 14
    Last Post: 09-06-2004, 04:04 PM
  3. pixels of bitmap
    By SuperNewbie in forum Windows Programming
    Replies: 4
    Last Post: 03-15-2004, 07:56 PM
  4. bitmap not going onto screen
    By stallion in forum Windows Programming
    Replies: 4
    Last Post: 02-22-2003, 10:07 AM
  5. Saving a bitmap.
    By jdinger in forum Game Programming
    Replies: 4
    Last Post: 05-01-2002, 01:40 PM