- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am using rs2::pointcloud::calculate::get_vertices() for showing a point cloud with RealSense D435.
Now, I am wondering about the units of x,y and z in rs2::vertex; The z-coordinate seems like meters (it ranges from 0 to above 1 and the observed results corresponds to the real world distance in meters).
It would make sense, that the units of x and y are also in meters. But it seems like all values are strictly in the interval [-1,1]. But in my setting, there should be x and y values above +-1 meter;
Are the x and y coordinates in meters or not? And if not, how do I map them to real world untis?
Code snipplet:
const rs2::vertex * pVerticesTmp = NULL;
rs2::pointcloud pc;
pc.map_to(m_oFrameset.get_depth_frame()); //all points have coordinate system of the depth sensor
m_oDepthPointsInCameraSpace = pc.calculate(m_oFrameset.get_depth_frame()); //calculate the coordinates of the depth frame in the depth camera coordiante system
pVerticesTmp = m_oDepthPointsInCameraSpace.get_vertices();
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the context of point clouds, I wonder if the ranges refer to pixel depth, where 0 is minimum depth, 1 is maximum depth and -1 may refer to an area of the image where the camera cannot recognize any detail.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi MartyG,
the pointcloud consists of 640x480 3d vectors (x,y,z). The z-coordinate denotes the depth in meters. The interval of the z-coordinate is [0,zMax] with zMax>>1 m, somewhere 8 m or 10 m.
But the x and y coordinates are only in the range -1 to 1 (always). But what does this mean??? How do I scale the x and y coordinate to get the coordinates in units of meters.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The only other circumstances I know of when an X and Y axis might be -1, 0 and 1 are in representing the direction of a vector. For example, on a videogame joystick, the center position when the stick is left alone is 0, and when the stick is pressed, the fully-left and fully down positions are -1, whilst the fully right and fully up positions are 1.
I researched the matter carefully but could not find alternative explanations for why you may be getting these results. So it will be best if you wait for a response from an Intel support team member about the true meaning of these axis readings, as they may have knowledge or reference sources that I do not. Good luck!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
please ignore my post regarding the rs2::vertex units. It is all fine, now. The units for the x and y coordinates are meters. And the x and y coordinates are NOT restricted to +-1.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Ok, thank you very much for the update. Best of luck with your project!
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page