(The "Functon" is a compiler typo not mine :P)
my question,
What I need to do, is get the pointcloud(XYZRGBA) data from pcl unmanaged C++, to C#.
I do this with the following code:
Unmanaged.cpp (C++)
float* getCloud(int clr_width, int clr_height, int dpth_width,
int dpth_height, int frameId, int clr_focal_x, int clr_focal_y,
int dpth_focal_x, int dpth_focal_y, unsigned char *image,
unsigned char *depth_image) const
{
(some implementation);
}
END OF Unmanaged.cpp
.
Managed.cpp (C++)
property float[]^ Receiver
{
float[]^ get()
{
return gcnew float[]( Unmanaged->getCloud((int)clr_width,
(int)clr_height, (int)dpth_width, (int)dpth_height, (int)frameId,
(int)clr_focal_x, (int)clr_focal_y, (int)dpth_focal_x,
(int)dpth_focal_y, (unsigned char*)image,
(unsigned char*)depth_image) );
}
}
END OF Managed.cpp
What I get is the error from the title:
'Kinecter::getCloud' : this functon cannot be compiled as managed, consider using #pragma unmanaged
Does someone know how to fix this?
Btw: The suggestion: #pragma unmanaged also doesn't work :(