We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hi everyone!
I have a problem. I am tring to use the pointclouds from kinect, by SimpleopenNI library, to Vec3D array of toxiclibs.
The problem is that :
PVector[] realWorldMap = kinect.depthMapRealWorld();
for store all points on an array, it does not work with:
Vec3D[] realWorldMap = kinect.depthMapRealWorld();
And I can not translate from PVector to Vec3D... Any suggest?
Answers
Although I don't have Toxic library installed here, I believe a Vec3D is almost the same as a PVector.
That is, they have in common these 3
float
properties: x, y & z.So in case I'm not wrong about it, it's just a matter of passing those 3 values to a
new
Vec3D.Here's a simple working test:
Thank you @GoToLoop !
I was looking for a for use directly toxiclibs with simpleopenni libraries, but your way is interesting and helpful too! I tested your code and it look like a good and fast way. I will implement it on the kinect code and I will update how it will work.