- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I wanto use the every Pixel of Depth stream to get 3D position which include Dist x,y,z and Degrees X,Y,Z. Dose the SDK include this algorithm?
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, you can access depth data of all pixels. Please refer to the background segmentation tutorial, and specially the sample code at
https://software.intel.com/sites/default/files/managed/66/9c/Background_Segmentation.pdf
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, I apologize, I think the link Pudubu shared is not helpful. To transform the depth image values to 3D coordinates, check the documentation for the PXCProjection interface:
Try this (pseudocode):
PXCProjection * projection = sensemanager->QueryCaptureManager()->QueryDevice()->CreateProjection();
PXCPoint3DF32 depthCoords[width * height * 3];
while(loop) {
sensemanager->AcquireFrame();
PXCCapture::Sample * sample = sensemanger->QuerySample();
PXCImage * depthMap = sample->depth;
projection->QueryVertices(depthMap,(PXCPoint3DF32 *) depthCoords);
//Do something with your coordinates//
sensemanager->ReleaseFrame();
}
Your 3D points will be in the depthCoords array, packed as [x,y,z] in millimeters, with one set of 3 floats for each of the original depth map pixels, in "raster order", and using the coordinate system described here:
Note: many of the resulting coordinates will be zeros, but that only means that those pixels were either saturated or too far for detection. There will be usable depth points deeper into the array.
Hope this helps.

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page