| 52 | } |
| 53 | |
| 54 | void GridMapPclLoader::preProcessInputCloud() { |
| 55 | // Preprocess: Remove outliers, downsample cloud, transform cloud |
| 56 | ROS_INFO_STREAM("Preprocessing of the pointcloud started"); |
| 57 | |
| 58 | if (params_.get().outlierRemoval_.isRemoveOutliers_) { |
| 59 | auto filteredCloud = pointcloudProcessor_.removeOutliersFromInputCloud(workingCloud_); |
| 60 | setWorkingCloud(filteredCloud); |
| 61 | } |
| 62 | |
| 63 | if (params_.get().downsampling_.isDownsampleCloud_) { |
| 64 | auto downsampledCloud = pointcloudProcessor_.downsampleInputCloud(workingCloud_); |
| 65 | setWorkingCloud(downsampledCloud); |
| 66 | } |
| 67 | |
| 68 | auto transformedCloud = pointcloudProcessor_.applyRigidBodyTransformation(workingCloud_); |
| 69 | setWorkingCloud(transformedCloud); |
| 70 | ROS_INFO_STREAM("Preprocessing and filtering finished"); |
| 71 | } |
| 72 | |
| 73 | void GridMapPclLoader::initializeGridMapGeometryFromInputCloud() { |
| 74 | workingGridMap_.clearAll(); |