Click to See Complete Forum and Search --> : DirectX : Transfer bitmap data to offscreen


Weiye
August 2nd, 1999, 09:13 AM
I have some trouble copying the bitmap data (which i have loaded from file [???.bmp]) onto a DirectDraw surface which i have created.

Say :

BYTE* bypBuffer; // points to actual bitmap data
LPDIRECTDRAWSURFACE lpDDS; // points to a created offscreen

How do i transfer the data from bypBuffer to lpDDS to be display on screen?

Sufyan
August 4th, 1999, 03:39 AM
Hi,
if u r using LoadImage to load the bitmap then u can put it on the surface using BitBlt else if u have the ptr to the bitmap data, then can do it using StretchDIBits.
Let me know if u have any probs.
- Sufyan.