RTAB-Map 0.23.10
Real-Time Appearance-Based Mapping
Loading...
Searching...
No Matches
util3d_filtering.h
1/*
2Copyright (c) 2010-2016, Mathieu Labbe - IntRoLab - Universite de Sherbrooke
3All rights reserved.
4
5Redistribution and use in source and binary forms, with or without
6modification, are permitted provided that the following conditions are met:
7 * Redistributions of source code must retain the above copyright
8 notice, this list of conditions and the following disclaimer.
9 * Redistributions in binary form must reproduce the above copyright
10 notice, this list of conditions and the following disclaimer in the
11 documentation and/or other materials provided with the distribution.
12 * Neither the name of the Universite de Sherbrooke nor the
13 names of its contributors may be used to endorse or promote products
14 derived from this software without specific prior written permission.
15
16THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
17ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY
20DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26*/
27
28#ifndef UTIL3D_FILTERING_H_
29#define UTIL3D_FILTERING_H_
30
31#include <rtabmap/core/rtabmap_core_export.h>
32#include <rtabmap/core/Transform.h>
33#include <pcl/point_cloud.h>
34#include <pcl/point_types.h>
35#include <pcl/pcl_base.h>
36#include <pcl/ModelCoefficients.h>
37#include <rtabmap/core/LaserScan.h>
38
39namespace rtabmap
40{
41
42namespace util3d
43{
44
79LaserScan RTABMAP_CORE_EXPORT commonFiltering(
80 const LaserScan & scan,
81 int downsamplingStep,
82 float rangeMin = 0.0f,
83 float rangeMax = 0.0f,
84 float voxelSize = 0.0f,
85 int normalK = 0,
86 float normalRadius = 0.0f,
87 float groundNormalsUp = 0.0f);
92RTABMAP_DEPRECATED LaserScan RTABMAP_CORE_EXPORT commonFiltering(
93 const LaserScan & scan,
94 int downsamplingStep,
95 float rangeMin,
96 float rangeMax,
97 float voxelSize,
98 int normalK,
99 float normalRadius,
100 bool forceGroundNormalsUp);
101
118LaserScan RTABMAP_CORE_EXPORT rangeFiltering(
119 const LaserScan & scan,
120 float rangeMin,
121 float rangeMax);
122
143pcl::IndicesPtr RTABMAP_CORE_EXPORT rangeFiltering(
144 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
145 const pcl::IndicesPtr & indices,
146 float rangeMin,
147 float rangeMax);
149pcl::IndicesPtr RTABMAP_CORE_EXPORT rangeFiltering(
150 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
151 const pcl::IndicesPtr & indices,
152 float rangeMin,
153 float rangeMax);
155pcl::IndicesPtr RTABMAP_CORE_EXPORT rangeFiltering(
156 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
157 const pcl::IndicesPtr & indices,
158 float rangeMin,
159 float rangeMax);
161pcl::IndicesPtr RTABMAP_CORE_EXPORT rangeFiltering(
162 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
163 const pcl::IndicesPtr & indices,
164 float rangeMin,
165 float rangeMax);
188void RTABMAP_CORE_EXPORT rangeSplitFiltering(
189 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
190 const pcl::IndicesPtr & indices,
191 float range,
192 pcl::IndicesPtr & closeIndices,
193 pcl::IndicesPtr & farIndices);
195void RTABMAP_CORE_EXPORT rangeSplitFiltering(
196 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
197 const pcl::IndicesPtr & indices,
198 float range,
199 pcl::IndicesPtr & closeIndices,
200 pcl::IndicesPtr & farIndices);
202void RTABMAP_CORE_EXPORT rangeSplitFiltering(
203 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
204 const pcl::IndicesPtr & indices,
205 float range,
206 pcl::IndicesPtr & closeIndices,
207 pcl::IndicesPtr & farIndices);
209void RTABMAP_CORE_EXPORT rangeSplitFiltering(
210 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
211 const pcl::IndicesPtr & indices,
212 float range,
213 pcl::IndicesPtr & closeIndices,
214 pcl::IndicesPtr & farIndices);
239LaserScan RTABMAP_CORE_EXPORT downsample(
240 const LaserScan & cloud,
241 int step);
243pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT downsample(
244 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
245 int step);
247pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT downsample(
248 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
249 int step);
251pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT downsample(
252 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
253 int step);
255pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT downsample(
256 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
257 int step);
259pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT downsample(
260 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
261 int step);
263pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT downsample(
264 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
265 int step);
292pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT voxelize(
293 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
294 const pcl::IndicesPtr & indices,
295 float voxelSize);
297pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
298 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
299 const pcl::IndicesPtr & indices,
300 float voxelSize);
302pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT voxelize(
303 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
304 const pcl::IndicesPtr & indices,
305 float voxelSize);
307pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
308 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
309 const pcl::IndicesPtr & indices,
310 float voxelSize);
312pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT voxelize(
313 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
314 const pcl::IndicesPtr & indices,
315 float voxelSize);
317pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
318 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
319 const pcl::IndicesPtr & indices,
320 float voxelSize);
322pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT voxelize(
323 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
324 float voxelSize);
326pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
327 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
328 float voxelSize);
330pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT voxelize(
331 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
332 float voxelSize);
334pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
335 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
336 float voxelSize);
338pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT voxelize(
339 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
340 float voxelSize);
342pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT voxelize(
343 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
344 float voxelSize);
359inline pcl::PointCloud<pcl::PointXYZ>::Ptr uniformSampling(
360 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
361 float voxelSize)
362{
363 return voxelize(cloud, voxelSize);
364}
377inline pcl::PointCloud<pcl::PointXYZRGB>::Ptr uniformSampling(
378 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
379 float voxelSize)
380{
381 return voxelize(cloud, voxelSize);
382}
395inline pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr uniformSampling(
396 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
397 float voxelSize)
398{
399 return voxelize(cloud, voxelSize);
400}
401
402
419pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT randomSampling(
420 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
421 int samples);
423pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT randomSampling(
424 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
425 int samples);
427pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT randomSampling(
428 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
429 int samples);
431pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT randomSampling(
432 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
433 int samples);
435pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT randomSampling(
436 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
437 int samples);
439pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT randomSampling(
440 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
441 int samples);
468pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
469 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
470 const pcl::IndicesPtr & indices,
471 const std::string & axis,
472 float min,
473 float max,
474 bool negative = false);
476pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
477 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
478 const pcl::IndicesPtr & indices,
479 const std::string & axis,
480 float min,
481 float max,
482 bool negative = false);
484pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
485 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
486 const pcl::IndicesPtr & indices,
487 const std::string & axis,
488 float min,
489 float max,
490 bool negative = false);
492pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
493 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
494 const pcl::IndicesPtr & indices,
495 const std::string & axis,
496 float min,
497 float max,
498 bool negative = false);
500pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
501 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
502 const pcl::IndicesPtr & indices,
503 const std::string & axis,
504 float min,
505 float max,
506 bool negative = false);
508pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(
509 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
510 const pcl::IndicesPtr & indices,
511 const std::string & axis,
512 float min,
513 float max,
514 bool negative = false);
516pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT passThrough(
517 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
518 const std::string & axis,
519 float min,
520 float max,
521 bool negative = false);
523pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT passThrough(
524 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
525 const std::string & axis,
526 float min,
527 float max,
528 bool negative = false);
530pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT passThrough(
531 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
532 const std::string & axis,
533 float min,
534 float max,
535 bool negative = false);
537pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT passThrough(
538 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
539 const std::string & axis,
540 float min,
541 float max,
542 bool negative = false);
544pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT passThrough(
545 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
546 const std::string & axis,
547 float min,
548 float max,
549 bool negative = false);
551pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT passThrough(
552 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
553 const std::string & axis,
554 float min,
555 float max,
556 bool negative = false);
582pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
583 const pcl::PCLPointCloud2::Ptr & cloud,
584 const pcl::IndicesPtr & indices,
585 const Eigen::Vector4f & min,
586 const Eigen::Vector4f & max,
587 const Transform & transform = Transform::getIdentity(),
588 bool negative = false);
590pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
591 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
592 const pcl::IndicesPtr & indices,
593 const Eigen::Vector4f & min,
594 const Eigen::Vector4f & max,
595 const Transform & transform = Transform::getIdentity(),
596 bool negative = false);
598pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
599 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
600 const pcl::IndicesPtr & indices,
601 const Eigen::Vector4f & min,
602 const Eigen::Vector4f & max,
603 const Transform & transform = Transform::getIdentity(),
604 bool negative = false);
606pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
607 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
608 const pcl::IndicesPtr & indices,
609 const Eigen::Vector4f & min,
610 const Eigen::Vector4f & max,
611 const Transform & transform = Transform::getIdentity(),
612 bool negative = false);
614pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
615 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
616 const pcl::IndicesPtr & indices,
617 const Eigen::Vector4f & min,
618 const Eigen::Vector4f & max,
619 const Transform & transform = Transform::getIdentity(),
620 bool negative = false);
622pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
623 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
624 const pcl::IndicesPtr & indices,
625 const Eigen::Vector4f & min,
626 const Eigen::Vector4f & max,
627 const Transform & transform = Transform::getIdentity(),
628 bool negative = false);
630pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(
631 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
632 const pcl::IndicesPtr & indices,
633 const Eigen::Vector4f & min,
634 const Eigen::Vector4f & max,
635 const Transform & transform = Transform::getIdentity(),
636 bool negative = false);
638pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT cropBox(
639 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
640 const Eigen::Vector4f & min,
641 const Eigen::Vector4f & max,
642 const Transform & transform = Transform::getIdentity(),
643 bool negative = false);
645pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT cropBox(
646 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
647 const Eigen::Vector4f & min,
648 const Eigen::Vector4f & max,
649 const Transform & transform = Transform::getIdentity(),
650 bool negative = false);
652pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT cropBox(
653 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
654 const Eigen::Vector4f & min,
655 const Eigen::Vector4f & max,
656 const Transform & transform = Transform::getIdentity(),
657 bool negative = false);
659pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT cropBox(
660 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
661 const Eigen::Vector4f & min,
662 const Eigen::Vector4f & max,
663 const Transform & transform = Transform::getIdentity(),
664 bool negative = false);
666pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT cropBox(
667 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
668 const Eigen::Vector4f & min,
669 const Eigen::Vector4f & max,
670 const Transform & transform = Transform::getIdentity(),
671 bool negative = false);
673pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT cropBox(
674 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
675 const Eigen::Vector4f & min,
676 const Eigen::Vector4f & max,
677 const Transform & transform = Transform::getIdentity(),
678 bool negative = false);
713pcl::IndicesPtr RTABMAP_CORE_EXPORT frustumFiltering(
714 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
715 const pcl::IndicesPtr & indices,
716 const Transform & cameraPose,
717 float horizontalFOV,
718 float verticalFOV,
719 float nearClipPlaneDistance,
720 float farClipPlaneDistance,
721 bool negative = false);
723pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT frustumFiltering(
724 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
725 const Transform & cameraPose,
726 float horizontalFOV,
727 float verticalFOV,
728 float nearClipPlaneDistance,
729 float farClipPlaneDistance,
730 bool negative = false);
732pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT frustumFiltering(
733 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
734 const Transform & cameraPose,
735 float horizontalFOV,
736 float verticalFOV,
737 float nearClipPlaneDistance,
738 float farClipPlaneDistance,
739 bool negative = false);
759pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT removeNaNFromPointCloud(
760 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud);
762pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT removeNaNFromPointCloud(
763 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud);
765pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT removeNaNFromPointCloud(
766 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud);
768pcl::PCLPointCloud2::Ptr RTABMAP_CORE_EXPORT removeNaNFromPointCloud(
769 const pcl::PCLPointCloud2::Ptr & cloud);
787pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT removeNaNNormalsFromPointCloud(
788 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud);
790pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT removeNaNNormalsFromPointCloud(
791 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud);
793pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT removeNaNNormalsFromPointCloud(
794 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud);
821pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
822 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
823 float radiusSearch,
824 int minNeighborsInRadius);
826pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
827 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
828 float radiusSearch,
829 int minNeighborsInRadius);
831pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
832 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
833 float radiusSearch,
834 int minNeighborsInRadius);
836pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
837 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
838 float radiusSearch,
839 int minNeighborsInRadius);
841pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
842 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
843 float radiusSearch,
844 int minNeighborsInRadius);
846pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
847 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
848 float radiusSearch,
849 int minNeighborsInRadius);
851pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
852 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
853 const pcl::IndicesPtr & indices,
854 float radiusSearch,
855 int minNeighborsInRadius);
857pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
858 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
859 const pcl::IndicesPtr & indices,
860 float radiusSearch,
861 int minNeighborsInRadius);
863pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
864 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
865 const pcl::IndicesPtr & indices,
866 float radiusSearch,
867 int minNeighborsInRadius);
869pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
870 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
871 const pcl::IndicesPtr & indices,
872 float radiusSearch,
873 int minNeighborsInRadius);
875pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
876 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
877 const pcl::IndicesPtr & indices,
878 float radiusSearch,
879 int minNeighborsInRadius);
881pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(
882 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
883 const pcl::IndicesPtr & indices,
884 float radiusSearch,
885 int minNeighborsInRadius);
926pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
927 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
928 const std::vector<int> & viewpointIndices,
929 const std::map<int, Transform> & viewpoints,
930 float factor=0.01f,
931 float neighborScale=2.0f);
933pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
934 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
935 const std::vector<int> & viewpointIndices,
936 const std::map<int, Transform> & viewpoints,
937 float factor=0.01f,
938 float neighborScale=2.0f);
940pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
941 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
942 const std::vector<int> & viewpointIndices,
943 const std::map<int, Transform> & viewpoints,
944 float factor=0.01f,
945 float neighborScale=2.0f);
947pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
948 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
949 const std::vector<int> & viewpointIndices,
950 const std::map<int, Transform> & viewpoints,
951 float factor=0.01f,
952 float neighborScale=2.0f);
954pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
955 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
956 const std::vector<int> & viewpointIndices,
957 const std::map<int, Transform> & viewpoints,
958 float factor=0.01f,
959 float neighborScale=2.0f);
961pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
962 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
963 const std::vector<int> & viewpointIndices,
964 const std::map<int, Transform> & viewpoints,
965 float factor=0.01f,
966 float neighborScale=2.0f);
967
969pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
970 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
971 const pcl::IndicesPtr & indices,
972 const std::vector<int> & viewpointIndices,
973 const std::map<int, Transform> & viewpoints,
974 float factor=0.01f,
975 float neighborScale=2.0f);
977pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
978 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
979 const pcl::IndicesPtr & indices,
980 const std::vector<int> & viewpointIndices,
981 const std::map<int, Transform> & viewpoints,
982 float factor=0.01f,
983 float neighborScale=2.0f);
985pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
986 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
987 const pcl::IndicesPtr & indices,
988 const std::vector<int> & viewpointIndices,
989 const std::map<int, Transform> & viewpoints,
990 float factor=0.01f,
991 float neighborScale=2.0f);
993pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
994 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
995 const pcl::IndicesPtr & indices,
996 const std::vector<int> & viewpointIndices,
997 const std::map<int, Transform> & viewpoints,
998 float factor=0.01f,
999 float neighborScale=2.0f);
1001pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
1002 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
1003 const pcl::IndicesPtr & indices,
1004 const std::vector<int> & viewpointIndices,
1005 const std::map<int, Transform> & viewpoints,
1006 float factor=0.01f,
1007 float neighborScale=2.0f);
1009pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(
1010 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1011 const pcl::IndicesPtr & indices,
1012 const std::vector<int> & viewpointIndices,
1013 const std::map<int, Transform> & viewpoints,
1014 float factor=0.01f,
1015 float neighborScale=2.0f);
1040pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(
1041 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1042 const pcl::IndicesPtr & indices,
1043 const pcl::PointCloud<pcl::PointXYZ>::Ptr & subtractCloud,
1044 const pcl::IndicesPtr & subtractIndices,
1045 float radiusSearch,
1046 int minNeighborsInRadius = 1);
1048pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(
1049 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1050 const pcl::IndicesPtr & indices,
1051 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & subtractCloud,
1052 const pcl::IndicesPtr & subtractIndices,
1053 float radiusSearch,
1054 int minNeighborsInRadius = 1);
1056pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(
1057 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
1058 const pcl::IndicesPtr & indices,
1059 const pcl::PointCloud<pcl::PointNormal>::Ptr & subtractCloud,
1060 const pcl::IndicesPtr & subtractIndices,
1061 float radiusSearch,
1062 float maxAngle = M_PI/4.0f,
1063 int minNeighborsInRadius = 1);
1065pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(
1066 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1067 const pcl::IndicesPtr & indices,
1068 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & subtractCloud,
1069 const pcl::IndicesPtr & subtractIndices,
1070 float radiusSearch,
1071 float maxAngle = M_PI/4.0f,
1072 int minNeighborsInRadius = 1);
1074pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(
1075 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1076 const pcl::IndicesPtr & indices,
1077 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & subtractCloud,
1078 const pcl::IndicesPtr & subtractIndices,
1079 float radiusSearch,
1080 float maxAngle = M_PI/4.0f,
1081 int minNeighborsInRadius = 1);
1083pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT subtractFiltering(
1084 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1085 const pcl::PointCloud<pcl::PointXYZ>::Ptr & subtractCloud,
1086 float radiusSearch,
1087 int minNeighborsInRadius = 1);
1089pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT subtractFiltering(
1090 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1091 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & subtractCloud,
1092 float radiusSearch,
1093 int minNeighborsInRadius = 1);
1095pcl::PointCloud<pcl::PointNormal>::Ptr RTABMAP_CORE_EXPORT subtractFiltering(
1096 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
1097 const pcl::PointCloud<pcl::PointNormal>::Ptr & subtractCloud,
1098 float radiusSearch,
1099 float maxAngle = M_PI/4.0f,
1100 int minNeighborsInRadius = 1);
1102pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT subtractFiltering(
1103 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1104 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & subtractCloud,
1105 float radiusSearch,
1106 float maxAngle = M_PI/4.0f,
1107 int minNeighborsInRadius = 1);
1109pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT subtractFiltering(
1110 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1111 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & subtractCloud,
1112 float radiusSearch,
1113 float maxAngle = M_PI/4.0f,
1114 int minNeighborsInRadius = 1);
1138pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractAdaptiveFiltering(
1139 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1140 const pcl::IndicesPtr & indices,
1141 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & subtractCloud,
1142 const pcl::IndicesPtr & subtractIndices,
1143 float radiusSearchRatio = 0.01,
1144 int minNeighborsInRadius = 1,
1145 const Eigen::Vector3f & viewpoint = Eigen::Vector3f(0,0,0));
1146
1174pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractAdaptiveFiltering(
1175 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1176 const pcl::IndicesPtr & indices,
1177 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & subtractCloud,
1178 const pcl::IndicesPtr & subtractIndices,
1179 float radiusSearchRatio = 0.01,
1180 float maxAngle = M_PI/4.0f,
1181 int minNeighborsInRadius = 1,
1182 const Eigen::Vector3f & viewpoint = Eigen::Vector3f(0,0,0));
1183
1184
1215pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1216 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1217 float angleMax,
1218 const Eigen::Vector4f & normal,
1219 int normalKSearch,
1220 const Eigen::Vector4f & viewpoint,
1221 float groundNormalsUp = 0.0f);
1223pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1224 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1225 float angleMax,
1226 const Eigen::Vector4f & normal,
1227 int normalKSearch,
1228 const Eigen::Vector4f & viewpoint,
1229 float groundNormalsUp = 0.0f);
1231pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1232 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1233 const pcl::IndicesPtr & indices,
1234 float angleMax,
1235 const Eigen::Vector4f & normal,
1236 int normalKSearch,
1237 const Eigen::Vector4f & viewpoint,
1238 float groundNormalsUp = 0.0f);
1240pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1241 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1242 const pcl::IndicesPtr & indices,
1243 float angleMax,
1244 const Eigen::Vector4f & normal,
1245 int normalKSearch,
1246 const Eigen::Vector4f & viewpoint,
1247 float groundNormalsUp = 0.0f);
1249pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1250 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
1251 const pcl::IndicesPtr & indices,
1252 float angleMax,
1253 const Eigen::Vector4f & normal,
1254 int normalKSearch,
1255 const Eigen::Vector4f & viewpoint,
1256 float groundNormalsUp = 0.0f);
1258pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1259 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
1260 const pcl::IndicesPtr & indices,
1261 float angleMax,
1262 const Eigen::Vector4f & normal,
1263 int normalKSearch,
1264 const Eigen::Vector4f & viewpoint,
1265 float groundNormalsUp = 0.0f);
1267pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1268 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1269 const pcl::IndicesPtr & indices,
1270 float angleMax,
1271 const Eigen::Vector4f & normal,
1272 int normalKSearch,
1273 const Eigen::Vector4f & viewpoint,
1274 float groundNormalsUp = 0.0f);
1276pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(
1277 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1278 const pcl::IndicesPtr & indices,
1279 float angleMax,
1280 const Eigen::Vector4f & normal,
1281 int normalKSearch,
1282 const Eigen::Vector4f & viewpoint,
1283 float groundNormalsUp = 0.0f);
1311std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1312 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1313 float clusterTolerance,
1314 int minClusterSize,
1315 int maxClusterSize = std::numeric_limits<int>::max(),
1316 int * biggestClusterIndex = 0);
1318std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1319 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1320 float clusterTolerance,
1321 int minClusterSize,
1322 int maxClusterSize = std::numeric_limits<int>::max(),
1323 int * biggestClusterIndex = 0);
1325std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1326 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1327 const pcl::IndicesPtr & indices,
1328 float clusterTolerance,
1329 int minClusterSize,
1330 int maxClusterSize = std::numeric_limits<int>::max(),
1331 int * biggestClusterIndex = 0);
1333std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1334 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
1335 const pcl::IndicesPtr & indices,
1336 float clusterTolerance,
1337 int minClusterSize,
1338 int maxClusterSize = std::numeric_limits<int>::max(),
1339 int * biggestClusterIndex = 0);
1341std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1342 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1343 const pcl::IndicesPtr & indices,
1344 float clusterTolerance,
1345 int minClusterSize,
1346 int maxClusterSize = std::numeric_limits<int>::max(),
1347 int * biggestClusterIndex = 0);
1349std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1350 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1351 const pcl::IndicesPtr & indices,
1352 float clusterTolerance,
1353 int minClusterSize,
1354 int maxClusterSize = std::numeric_limits<int>::max(),
1355 int * biggestClusterIndex = 0);
1357std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1358 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
1359 const pcl::IndicesPtr & indices,
1360 float clusterTolerance,
1361 int minClusterSize,
1362 int maxClusterSize = std::numeric_limits<int>::max(),
1363 int * biggestClusterIndex = 0);
1365std::vector<pcl::IndicesPtr> RTABMAP_CORE_EXPORT extractClusters(
1366 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1367 const pcl::IndicesPtr & indices,
1368 float clusterTolerance,
1369 int minClusterSize,
1370 int maxClusterSize = std::numeric_limits<int>::max(),
1371 int * biggestClusterIndex = 0);
1398pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1399 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1400 const pcl::IndicesPtr & indices,
1401 bool negative);
1403pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1404 const pcl::PointCloud<pcl::PointNormal>::Ptr & cloud,
1405 const pcl::IndicesPtr & indices,
1406 bool negative);
1408pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1409 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1410 const pcl::IndicesPtr & indices,
1411 bool negative);
1413pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1414 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1415 const pcl::IndicesPtr & indices,
1416 bool negative);
1418pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1419 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
1420 const pcl::IndicesPtr & indices,
1421 bool negative);
1423pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(
1424 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1425 const pcl::IndicesPtr & indices,
1426 bool negative);
1428pcl::PointCloud<pcl::PointXYZ>::Ptr RTABMAP_CORE_EXPORT extractIndices(
1429 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1430 const pcl::IndicesPtr & indices,
1431 bool negative,
1432 bool keepOrganized);
1434pcl::PointCloud<pcl::PointXYZRGB>::Ptr RTABMAP_CORE_EXPORT extractIndices(
1435 const pcl::PointCloud<pcl::PointXYZRGB>::Ptr & cloud,
1436 const pcl::IndicesPtr & indices,
1437 bool negative,
1438 bool keepOrganized);
1440pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr RTABMAP_CORE_EXPORT extractIndices(
1441 const pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & cloud,
1442 const pcl::IndicesPtr & indices,
1443 bool negative,
1444 bool keepOrganized);
1446pcl::PointCloud<pcl::PointXYZI>::Ptr RTABMAP_CORE_EXPORT extractIndices(
1447 const pcl::PointCloud<pcl::PointXYZI>::Ptr & cloud,
1448 const pcl::IndicesPtr & indices,
1449 bool negative,
1450 bool keepOrganized);
1452pcl::PointCloud<pcl::PointXYZINormal>::Ptr RTABMAP_CORE_EXPORT extractIndices(
1453 const pcl::PointCloud<pcl::PointXYZINormal>::Ptr & cloud,
1454 const pcl::IndicesPtr & indices,
1455 bool negative,
1456 bool keepOrganized);
1479pcl::IndicesPtr RTABMAP_CORE_EXPORT extractPlane(
1480 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1481 const pcl::IndicesPtr & indices,
1482 float distanceThreshold,
1483 int maxIterations = 100,
1484 pcl::ModelCoefficients * coefficientsOut = 0);
1485pcl::IndicesPtr RTABMAP_CORE_EXPORT extractPlane(
1486 const pcl::PointCloud<pcl::PointXYZ>::Ptr & cloud,
1487 float distanceThreshold,
1488 int maxIterations = 100,
1489 pcl::ModelCoefficients * coefficientsOut = 0);
1490
1491} // namespace util3d
1492} // namespace rtabmap
1493
1494#endif /* UTIL3D_FILTERING_H_ */
Represents 2D or 3D laser scan data with support for multiple point data formats.
Definition LaserScan.h:46
Represents a 3D rigid body transformation (rotation + translation).
Definition Transform.h:53
static Transform getIdentity()
Returns identity transform.
pcl::IndicesPtr RTABMAP_CORE_EXPORT cropBox(const pcl::PCLPointCloud2::Ptr &cloud, const pcl::IndicesPtr &indices, const Eigen::Vector4f &min, const Eigen::Vector4f &max, const Transform &transform=Transform::getIdentity(), bool negative=false)
Performs crop box filtering on a point cloud of type pcl::PCLPointCloud2 and returns filtered indices...
std::vector< pcl::IndicesPtr > RTABMAP_CORE_EXPORT extractClusters(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, float clusterTolerance, int minClusterSize, int maxClusterSize=std::numeric_limits< int >::max(), int *biggestClusterIndex=0)
Extract clusters from point cloud of type pcl::PointXYZ.
pcl::IndicesPtr RTABMAP_CORE_EXPORT extractIndices(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, bool negative)
Extract indices from point cloud of type pcl::PointXYZ.
pcl::IndicesPtr RTABMAP_CORE_EXPORT frustumFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, const Transform &cameraPose, float horizontalFOV, float verticalFOV, float nearClipPlaneDistance, float farClipPlaneDistance, bool negative=false)
Performs frustum filtering on a point cloud of type pcl::PointXYZ and returns filtered indices.
pcl::IndicesPtr RTABMAP_CORE_EXPORT passThrough(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, const std::string &axis, float min, float max, bool negative=false)
Performs pass-through filtering on a point cloud of type pcl::PointXYZ and returns filtered indices.
LaserScan RTABMAP_CORE_EXPORT downsample(const LaserScan &cloud, int step)
Downsamples a LaserScan.
void RTABMAP_CORE_EXPORT rangeSplitFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, float range, pcl::IndicesPtr &closeIndices, pcl::IndicesPtr &farIndices)
Splits a point cloud of type pcl::PointXYZ.
pcl::IndicesPtr RTABMAP_CORE_EXPORT normalFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, float angleMax, const Eigen::Vector4f &normal, int normalKSearch, const Eigen::Vector4f &viewpoint, float groundNormalsUp=0.0f)
Point normal filtering for point cloud of type pcl::PointXYZ.
pcl::IndicesPtr RTABMAP_CORE_EXPORT proportionalRadiusFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const std::vector< int > &viewpointIndices, const std::map< int, Transform > &viewpoints, float factor=0.01f, float neighborScale=2.0f)
Proportional radius filtering for point cloud of type pcl::PointXYZ.
pcl::IndicesPtr RTABMAP_CORE_EXPORT radiusFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, float radiusSearch, int minNeighborsInRadius)
Radius filtering for point cloud of type pcl::PointXYZ.
pcl::PointCloud< pcl::PointXYZ >::Ptr RTABMAP_CORE_EXPORT randomSampling(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, int samples)
Performs random sampling on a point cloud of type pcl::PointXYZ.
pcl::PointCloud< pcl::PointXYZ >::Ptr RTABMAP_CORE_EXPORT removeNaNFromPointCloud(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud)
Remove NaN points from a point cloud of type pcl::PointXYZ.
pcl::PointCloud< pcl::PointNormal >::Ptr RTABMAP_CORE_EXPORT removeNaNNormalsFromPointCloud(const pcl::PointCloud< pcl::PointNormal >::Ptr &cloud)
Removes points with NaN normal values from a point cloud of type pcl::PointNormal.
pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractFiltering(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, const pcl::PointCloud< pcl::PointXYZ >::Ptr &subtractCloud, const pcl::IndicesPtr &subtractIndices, float radiusSearch, int minNeighborsInRadius=1)
Subtract filtering for point cloud of type pcl::PointXYZ, returning filtered indices.
pcl::PointCloud< pcl::PointXYZ >::Ptr RTABMAP_CORE_EXPORT voxelize(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, float voxelSize)
Performs voxel grid downsampling on a point cloud of type pcl::PointXYZ on provided indices.
pcl::IndicesPtr RTABMAP_CORE_EXPORT subtractAdaptiveFiltering(const pcl::PointCloud< pcl::PointXYZRGB >::Ptr &cloud, const pcl::IndicesPtr &indices, const pcl::PointCloud< pcl::PointXYZRGB >::Ptr &subtractCloud, const pcl::IndicesPtr &subtractIndices, float radiusSearchRatio=0.01, int minNeighborsInRadius=1, const Eigen::Vector3f &viewpoint=Eigen::Vector3f(0, 0, 0))
Performs adaptive radius-based subtraction filtering on a point cloud.
LaserScan RTABMAP_CORE_EXPORT commonFiltering(const LaserScan &scan, int downsamplingStep, float rangeMin=0.0f, float rangeMax=0.0f, float voxelSize=0.0f, int normalK=0, float normalRadius=0.0f, float groundNormalsUp=0.0f)
Applies a common set of filters to a LaserScan, including downsampling, range limits,...
pcl::PointCloud< pcl::PointXYZ >::Ptr uniformSampling(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, float voxelSize)
DEPRECATED: Use voxelize() instead.
pcl::IndicesPtr RTABMAP_CORE_EXPORT extractPlane(const pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud, const pcl::IndicesPtr &indices, float distanceThreshold, int maxIterations=100, pcl::ModelCoefficients *coefficientsOut=0)
Extracts the indices of the inliers that belong to a plane using RANSAC.
LaserScan RTABMAP_CORE_EXPORT rangeFiltering(const LaserScan &scan, float rangeMin, float rangeMax)
Filters a LaserScan data on a minimum and maximum Euclidean range.