"NishCA" <no****@devdex.comschrieb
Hello..
I have got finger image data as raw pixel data scan lines from the
top, left to the bottom, right. Also, have image height & width in
pixels; BPP is avail.
I need to display this image data on VB application & have don't
have much experience in VB development, can some-one please help me
in displaying image data as bitmap or if i can save this data in
.bmp file.
You can use one overload of the Bitmap constructor:
Public Sub New(ByVal width As Integer, ByVal height As Integer, ByVal stride
As Integer, ByVal format As System.Drawing.Imaging.PixelFormat, ByVal scan0
As System.IntPtr)
You will probably have to be very carefull with the pointer (scan0). You get
it by creating a GC handle (GCHandle) using GCHandle.Alloc, then call
AddrOfPinnedObject of the returned object. Don't destroy it (by calling the
GCHandle's Free method) before the Bitmap is disposed. ..... I'm assuming
you have the pixel data in a byte array or similar. If you already have the
IntPtr, forget what I wrote.
Armin