Coordinates of a point

 Posts: 11
 Joined: 19 Jun 2013, 14:29
Coordinates of a point
Is it possible to know the coordinates of a point in the default floor ?(before or after simulation)
Re: Coordinates of a point
Hello,
Yes, of course! But the question is, what point?
To get the coordinates of an object (be it a dummy or another one), just use the simGetObjectPosition API function.
.. or are you talking about coordinate transformations?
Cheers
Yes, of course! But the question is, what point?
To get the coordinates of an object (be it a dummy or another one), just use the simGetObjectPosition API function.
.. or are you talking about coordinate transformations?
Cheers
Re: Coordinates of a point
Hello,
I have a question regarding the conversion of depth values into 3D point clouds and transformation to the world reference frame. I am using a Kinect Vision sensor. I set the angle of view using the focal length which i got by calibrating a real camera e.g. for a camera with focal length in pixels=534 i use the formula Angle=2*atan(640/ (534*2)), converting into degrees it came to about 61.86 degrees.
After that I retrieved the depth buffer, I write the depth buffer to a .txt file as explained in the other post a few days ago. Now using MATLAB i convert this depth map into a point cloud using the following code:
I also get the absolute position of the sensor using 'simGetObjectMatrix'. Now i apply this transformation matrix to the computed point cloud for two different sensors. I should actually get a well registered point cloud from both the sensors but instead i get weird transformations. I know there is something wrong in my interpretation fo the coordinate system. But i am not quite able to interpret what exactly is it?
I hope you will be able to help.
best regards
I have a question regarding the conversion of depth values into 3D point clouds and transformation to the world reference frame. I am using a Kinect Vision sensor. I set the angle of view using the focal length which i got by calibrating a real camera e.g. for a camera with focal length in pixels=534 i use the formula Angle=2*atan(640/ (534*2)), converting into degrees it came to about 61.86 degrees.
After that I retrieved the depth buffer, I write the depth buffer to a .txt file as explained in the other post a few days ago. Now using MATLAB i convert this depth map into a point cloud using the following code:
Code: Select all
%%dImage contains the depth values retrieved from vrep
for m=1:480
for n=1:640
Z=dImage(m,n)*1000;%%from mm to m
PointCloud(1,Count)=(ncx)*(Z/fx);%%X
PointCloud(2,Count)=(mcy)*(Z/fy);%%Y
PointCloud(3,Count)=Z;
Count=Count+1;
end
end
I hope you will be able to help.
best regards
Re: Coordinates of a point
Hello,
could you post this question to a new topic? This is not really related to current topic.
Thanks
could you post this question to a new topic? This is not really related to current topic.
Thanks