代码的问题在于cloudu是一个智能指针,不能直接使用size()方法获取其大小。应该使用->size()方法来获取PointCloud的大小。修改后的代码如下:

pcl::PointCloud<pcl::PointXYZRGB>::Ptr cloudu = clouds[i];
for (size_t j = 0; j < cloudu->size(); j++)

这样就可以正确地获取PointCloud的大小了。

检查代码pclPointCloudpclPointXYZRGBPtr cloudu = cloudsi;for size_t j = 0; j cloudusize; j++

原文地址: https://www.cveoy.top/t/topic/iQBd 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录