I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class.
My import looks like this:
[DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr GetBitmap(System.IntPtr hwnd, int nBMPWIDTH, int nBMPHEIGHT);
The H file section looks like:
Cbitmap* GetBitmap(HWND hwnd,int nBMPWIDTH,int nBMPHEIGHT);
How do I go about converting the Cbitmap into something I can display in C#?
Many thanks.