Click to See Complete Forum and Search --> : Display pixel buffer in sdi mfc window


eleven11
January 15th, 2007, 02:56 AM
Hi guys,

I have a vector of video frames called frameVector. So for example frameVector[0] is of type byte* and has a size of 230,400 bytes (width of 320 and height of 240 and 3 channels).

I want to display the frames in my sdi mfc program.

Could you please guide me roughly on how I can do that.

thx.

Mike Harnad
January 15th, 2007, 11:36 AM
CAnimateCtrl (http://msdn2.microsoft.com/en-us/library/z44k3stc(VS.80).aspx) ?

eleven11
January 16th, 2007, 12:45 AM
ok tnx.

let me read up a bit about this.

golanshahar
January 19th, 2007, 03:00 PM
You can do this with ::SetDIBitsToDevice(..) (http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/bitmaps_8e5h.asp).

look at this thread for sample: loading raw image in a frame (http://www.codeguru.com/forum/showthread.php?t=349556&p=1196189)

Cheers