diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloud.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloud.h index c2c38a990e6..fc66674ec26 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloud.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloud.h @@ -44,6 +44,9 @@ #include #include #include + +#include // for pcl::weak_ptr + #ifdef OPENGL_IS_A_FRAMEWORK # include # include @@ -75,6 +78,12 @@ class Cloud : public Statistics { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + + /// The type for weak pointer pointing to a selection buffer + using SelectionWeakPtr = pcl::weak_ptr; + /// @brief Default Constructor Cloud (); @@ -412,7 +421,7 @@ class Cloud : public Statistics /// @brief A weak pointer pointing to the selection object. /// @details This implementation uses the weak pointer to allow for a lazy /// update of the cloud if the selection object is destroyed. - std::weak_ptr selection_wk_ptr_; + SelectionWeakPtr selection_wk_ptr_; /// Flag that indicates whether a color ramp should be used (true) or not /// (false) when displaying the cloud diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloudEditorWidget.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloudEditorWidget.h index 9c2002ee676..de5b3b771d2 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloudEditorWidget.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cloudEditorWidget.h @@ -47,16 +47,23 @@ #include #include +#include // for pcl::shared_ptr + #include #include +class Selection; + /// @brief class declaration for the widget for editing and viewing /// point clouds. class CloudEditorWidget : public QGLWidget { Q_OBJECT public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param parent a pointer which points to the parent widget CloudEditorWidget (QWidget *parent = nullptr); diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/copyCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/copyCommand.h index d7dc85cb052..2da976ab097 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/copyCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/copyCommand.h @@ -44,9 +44,16 @@ #include #include +#include // for pcl::shared_ptr + +class Selection; + class CopyCommand : public Command { public: + /// The type for shared pointer pointing to a constant selection buffer + using ConstSelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param copy_buffer_ptr a shared pointer pointing to the copy buffer. /// @param selection_ptr a shared pointer pointing to the selection object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cutCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cutCommand.h index f5d28b3148d..438f11344da 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cutCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/cutCommand.h @@ -45,9 +45,14 @@ #include #include +#include // for pcl::shared_ptr + class CutCommand : public Command { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param copy_buffer_ptr a shared pointer pointing to the copy buffer. /// @param selection_ptr a shared pointer pointing to the selection object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/deleteCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/deleteCommand.h index caebdb58f7e..25c22ac08a5 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/deleteCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/deleteCommand.h @@ -45,9 +45,14 @@ #include #include +#include // for pcl::shared_ptr + class DeleteCommand : public Command { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr A shared pointer pointing to the selection object. /// @param cloud_ptr A shared pointer pointing to the cloud object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/denoiseCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/denoiseCommand.h index b01f7cf342a..73a1cd11b63 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/denoiseCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/denoiseCommand.h @@ -47,9 +47,14 @@ #include #include +#include // for pcl::shared_ptr + class DenoiseCommand : public Command { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr a shared pointer pointing to the selection object. /// @param cloud_ptr a shared pointer pointing to the cloud object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/pasteCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/pasteCommand.h index 2cc09ac2a35..787e6721dcd 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/pasteCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/pasteCommand.h @@ -43,9 +43,14 @@ #include #include +#include // for pcl::shared_ptr + class PasteCommand : public Command { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param copy_buffer_ptr a shared pointer pointing to the copy buffer. /// @param selection_ptr a shared pointer pointing to the selection object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select1DTool.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select1DTool.h index ee06d45b0a7..679e97bd855 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select1DTool.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select1DTool.h @@ -42,9 +42,16 @@ #include #include +#include // for pcl::shared_ptr + +class Selection; + class Select1DTool : public ToolInterface { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr a shared pointer pointing to the selection object. /// @param cloud_ptr a shared pointer pointing to the cloud object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select2DTool.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select2DTool.h index 1adb2486c8a..aacbbfbe6ec 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select2DTool.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/select2DTool.h @@ -44,9 +44,16 @@ #include #include +#include // for pcl::shared_ptr + +class Selection; + class Select2DTool : public ToolInterface { public: + /// The type for shared pointer pointing to a selection buffer + using SelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr a shared pointer pointing to the selection object. /// @param cloud_ptr a shared pointer pointing to the cloud object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/selectionTransformTool.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/selectionTransformTool.h index a07f960b518..976d1e98455 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/selectionTransformTool.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/selectionTransformTool.h @@ -43,6 +43,10 @@ #include #include +#include // for pcl::shared_ptr + +class Selection; + /// @brief The selection transform tool computes the transform matrix from /// mouse input. It then updates the cloud's transform matrix for the /// selected points so that the transformed and selected points will be @@ -53,6 +57,9 @@ class SelectionTransformTool : public ToolInterface { public: + /// The type for shared pointer pointing to a constant selection buffer + using ConstSelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr a shared pointer pointing to the selection object. /// @param cloud_ptr a shared pointer pointing to the cloud object. diff --git a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/transformCommand.h b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/transformCommand.h index 0e2537cb4e0..19b302d9a8f 100644 --- a/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/transformCommand.h +++ b/apps/point_cloud_editor/include/pcl/apps/point_cloud_editor/transformCommand.h @@ -44,9 +44,16 @@ #include #include +#include // for pcl::shared_ptr + +class Selection; + class TransformCommand : public Command { public: + /// The type for shared pointer pointing to a constant selection buffer + using ConstSelectionPtr = pcl::shared_ptr; + /// @brief Constructor /// @param selection_ptr a shared pointer pointing to the selection object. /// @param cloud_ptr a shared pointer pointing to the cloud object.