20 #ifndef POINTCLOUDMAPPING_H 21 #define POINTCLOUDMAPPING_H 25 #include <pcl/common/transforms.h> 26 #include <pcl/point_types.h> 27 #include <pcl/filters/voxel_grid.h> 28 #include <condition_variable> 29 #include <pcl/io/pcd_io.h> 44 int32_t GetPointCloudDataCacheIndex();
47 void insertKeyFrame(
KeyFrame* kf, cv::Mat& color, cv::Mat& depth );
51 bool* GetPointCloudState();
52 mutex* GetPointCloudMutex();
53 PointCloud::Ptr GetPointCloudPtr();
54 mutex* GetPointCloudStateMutex();
57 PointCloud::Ptr generatePointCloud(
KeyFrame* kf, cv::Mat& color, cv::Mat& depth);
63 bool shutDownFlag =
false;
64 bool bIsPointCloudGenerated =
false;
78 uint16_t lastKeyframeSize =0;
80 double resolution = 0.05;
87 #endif // POINTCLOUDMAPPING_H vector< cv::Mat > colorImgs
PointCloud::Ptr globalMapBack
DataCache< PointCloud > * mpPointCloudDataCache
vector< cv::Mat > depthImgs
shared_ptr< thread > viewerThread
PointCloud::Ptr globalMap
mutex keyFrameUpdateMutex
mutex globalMapStateMutex
pcl::PointCloud< PointT > PointCloud
vector< KeyFrame * > keyframes
pcl::VoxelGrid< PointT > voxel
condition_variable keyFrameUpdated