Reputation: 3125
This is very likely s a simple thing, but I am stuck. I am trying to initialize a Point Cloud Library Point cloud in a header file, so that I can share it across functions.
I am trying:
//.h
typedef pcl::PointCloud<pcl::POINT_TYPE> PointCloud;
PointCloud::Ptr currCloud;
//.cpp
currCloud= new pcl::PointCloud<pcl::PointXYZI>;
But this gives me
no operator '=' matches these operands
How can i initialize this type?
Thank you.
Upvotes: 0
Views: 5788
Reputation: 977
In PCL, the point types have to match between declaration and definitions.
Change
typedef pcl::PointCloud<pcl::POINT_TYPE> PointCloud;
to
typedef pcl::PointCloud<pcl::PointXYZI> PointCloud;
In your header.
Upvotes: 1