Get RAW Image from C++ Memory Pointer

xion

New member
Joined
Mar 15, 2005
Messages
2
Programming Experience
3-5
I've got great problems solving the following problem:

I've got some high speed camera that comes with an c++ api and SDK.
There is an OnFrameCapture callback Function that returns a
C++ pointer to the starting point of some RAW Image data stored in unmanaged Memory

Now I want to
1) Get the Image
2) convert it to jpeg
3) save it to hard disk

- I know some header data of the image like size, bits/p, pitch...
- The Pointer is returned as UInt32
- I also know the byte structure in memory (RGB24 / RGB32 / ...)

My Program is in vb.net, but I could also include some c# code...

All my tries ended up between the marshal class, API memory functions, unsafe code...

Please help me! It's urgent! (code should work on sunday :eek: )
thx in advance
 

TPM

Well-known member
Joined
Dec 7, 2004
Messages
623
Location
CA
Programming Experience
3-5
Not sure how much help this is but;
The type bitmap has built in functions to load, save and convert image files.

TPM
 

xion

New member
Joined
Mar 15, 2005
Messages
2
Programming Experience
3-5
TPM said:
Not sure how much help this is but;
The type bitmap has built in functions to load, save and convert image files.

TPM
Thx TPM, but the Problem is, that VB.NET can NOT access unmanaged memory areas directly.
There must be something to marshal....
 
Top Bottom