How to create a dynamic bitmap ?
-
hello, I want to create a dynamic Bitmap (size + data), what is the way doing this? I try to use CreateBitmap without big success. Thanks.
-
hello, I want to create a dynamic Bitmap (size + data), what is the way doing this? I try to use CreateBitmap without big success. Thanks.
Can you more explain about create a dynamic Bitmap
WhiteSky
-
hello, I want to create a dynamic Bitmap (size + data), what is the way doing this? I try to use CreateBitmap without big success. Thanks.
Please use the following code if u can use MFC. UINT BITS_IN_A_BYTE = 8; CBitmap BlankBmp; BYTE *pbyBits = 0; SIZE_T nBits; nBits = m_uImgWidth * m_uImgHeight; pbyBits = new BYTE[nBits + UNITY]; if( 0 == pbyBits ) { return; } // Fill it with Black RGB values (R=0, G=0, B=0) ZeroMemory( pbyBits, nBits + UNITY ); BlankBmp.CreateBitmap( m_uImgWidth, m_uImgHeight, 1, BITS_IN_A_BYTE, pbyBits ); delete[] pbyBits;
akt
-
hello, I want to create a dynamic Bitmap (size + data), what is the way doing this? I try to use CreateBitmap without big success. Thanks.
Using Win32 APIs or MFC? Do you want a DIB, DDB, or a DIB section? How many bits per pixel? Mark
"Posting a VB.NET question in the C++ forum will end in tears." Chris Maunder
-
Using Win32 APIs or MFC? Do you want a DIB, DDB, or a DIB section? How many bits per pixel? Mark
"Posting a VB.NET question in the C++ forum will end in tears." Chris Maunder
What is the diffrent between the above ? I need 32 bits per pixel (or 24). Thanks