내 프로젝트에서 intptr로 비트 맵을 변환하는 방법 EmguCV lib를 사용하고 싶지만 EmguCV의 기능이 Bitmap 객체를 처리 할 수 없기 때문에 Bitmap을 다른 유형으로 변환해야하지만 Intptr은 선택 사항이지만 정말 코딩하는 방법을 모르는, 동료 코드는 다음과 같은 내 프로젝트에서 추상적이다 :C에서 #
Bitmap bmp = new Bitmap(e.width, e.height,
System.Drawing.Imaging.PixelFormat.Format24bppRgb);
System.Drawing.Imaging.BitmapData data =
bmp.LockBits(new Rectangle(0, 0, e.width, e.height),
System.Drawing.Imaging.ImageLockMode.ReadWrite,
System.Drawing.Imaging.PixelFormat.Format24bppRgb);
int dataLength = e.width * e.height * 3;
Win32.memcpy(data.Scan0, (IntPtr)e.data, (uint)dataLength);
convertBitmapToIntptr(bmp);
어떻게 수있는이 기능 convertBitmapToIntptr(bmp)
에서 I 코드? 나는이 일을하고 한
당신이 수업 시간에이 포장 할
당신이 무엇을 요구하고 있는지 확실히 모르십니까? –
GetHbitmap()을 찾으십니까? http://msdn.microsoft.com/en-us/library/1dz311e4.aspx –