Hi,
I would like to be able to retrieve two pointclouds after calling zed->grab. For one pointcloud, I would like to set the depth confidence threshold at 100%, including all points, and then retrieve a second pointcloud for the same data at a confidence threshold of 80%. My rough script with pseudocode is:
while(1){
zed->setConfidenceThreshold(100);
zed->grab;
cv::Mat pointcloud_1, pointcloud_2;
// I have written it here, but I convert from sl::Mat to cv::Mat in the retrieve process.
zed->retrieveMeasure(sl::zed::POINTCLOUD).copyTo(pointcloud_1);
zed->setConfidenceThreshold(80);
zed->retrieveMeasure(sl::zed::POINTCLOUD).copyTo(pointcloud_2);
}
However, the pointcloud data seems to only be affected by the second confidence threshold.
I dug around some of the include files by stereolabs and I think one of the comments mentioned
having to clear the cpu buffer for multiple retrieveMeasures? Could you please clarify this and
perhaps provide a bit of example code which I could use to solve my problem. Thanks!
This issue is stale because it has been open 30 days with no activity. Remove stale label or comment otherwise it will be automatically closed in 5 days
Hi, I would like to be able to retrieve two pointclouds after calling zed->grab. For one pointcloud, I would like to set the depth confidence threshold at 100%, including all points, and then retrieve a second pointcloud for the same data at a confidence threshold of 80%. My rough script with pseudocode is:
while(1){ zed->setConfidenceThreshold(100); zed->grab; cv::Mat pointcloud_1, pointcloud_2; // I have written it here, but I convert from sl::Mat to cv::Mat in the retrieve process. zed->retrieveMeasure(sl::zed::POINTCLOUD).copyTo(pointcloud_1); zed->setConfidenceThreshold(80); zed->retrieveMeasure(sl::zed::POINTCLOUD).copyTo(pointcloud_2); }
However, the pointcloud data seems to only be affected by the second confidence threshold. I dug around some of the include files by stereolabs and I think one of the comments mentioned having to clear the cpu buffer for multiple retrieveMeasures? Could you please clarify this and perhaps provide a bit of example code which I could use to solve my problem. Thanks!