Skip to content

Commit d9160f8

Browse files
committed
remove return_in_cam_frame flag
1 parent 348fe56 commit d9160f8

5 files changed

Lines changed: 14 additions & 27 deletions

File tree

beam_colorize/include/beam_colorize/Colorizer.h

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -91,21 +91,18 @@ class Colorizer {
9191
void SetDistortion(const bool& image_distored);
9292

9393
/**
94-
* @brief Pure virtual method for colorizing a point cloud
95-
* @param return_in_cam_frame set to false to return the cloud in its original
96-
* frame. Internally, when a cloud is added it's converted to the camera
97-
* frame, so here when we return the pointcloud it can be in either frame.
94+
* @brief Pure virtual method for colorizing a point cloud.
9895
* @return Colored point cloud pointer
9996
*/
100-
virtual pcl::PointCloud<pcl::PointXYZRGB>::Ptr
101-
ColorizePointCloud(bool return_in_cam_frame = false) const = 0;
97+
virtual pcl::PointCloud<pcl::PointXYZRGB>::Ptr ColorizePointCloud() const = 0;
10298

10399
/**
104-
* @brief Pure virtual method for colorizing a point cloud
100+
* @brief Pure virtual method for colorizing a point cloud. Returned point
101+
* cloud will be in camera frame
105102
* @return Colored point cloud pointer
106103
*/
107104
virtual pcl::PointCloud<beam_containers::PointBridge>::Ptr
108-
ColorizeMask(bool return_in_cam_frame = false) const = 0;
105+
ColorizeMask() const = 0;
109106

110107
protected:
111108
pcl::PointCloud<pcl::PointXYZRGB>::Ptr GetCloudInLidarFrame(

beam_colorize/include/beam_colorize/Projection.h

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,10 @@ class Projection : public Colorizer {
2020
~Projection() override = default;
2121

2222
/**
23-
* @brief Method for colorizing a point cloud
24-
* @param return_in_cam_frame set to false to return the cloud in its original
25-
* frame. Internally, when a cloud is added it's converted to the camera
26-
* frame, so here when we return the pointcloud it can be in either frame.
27-
* @return Colored point cloud pointer
23+
* @brief see Colorizer.h
2824
*/
2925
pcl::PointCloud<pcl::PointXYZRGB>::Ptr
30-
ColorizePointCloud(bool return_in_cam_frame = false) const override;
26+
ColorizePointCloud() const override;
3127

3228
/**
3329
* @brief see Colorizer.h

beam_colorize/include/beam_colorize/RayTrace.h

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,15 @@ class RayTrace : public Colorizer {
2626
~RayTrace() = default;
2727

2828
/**
29-
* @brief Method for colorizing a point cloud
30-
* @param return_in_cam_frame set to false to return the cloud in its original
31-
* frame. Internally, when a cloud is added it's converted to the camera
32-
* frame, so here when we return the pointcloud it can be in either frame.
33-
* @return Colored point cloud pointer
29+
* @brief see Colorizer.h
3430
*/
35-
pcl::PointCloud<pcl::PointXYZRGB>::Ptr
36-
ColorizePointCloud(bool return_in_cam_frame = false) const override;
31+
pcl::PointCloud<pcl::PointXYZRGB>::Ptr ColorizePointCloud() const override;
3732

3833
/**
3934
* @brief see Colorizer.h
4035
*/
4136
virtual pcl::PointCloud<beam_containers::PointBridge>::Ptr
42-
ColorizeMask(bool return_in_cam_frame = false) const override;
37+
ColorizeMask() const override;
4338

4439
private:
4540
/**

beam_colorize/src/Projection.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@ namespace beam_colorize {
77

88
Projection::Projection() : Colorizer() {}
99

10-
pcl::PointCloud<pcl::PointXYZRGB>::Ptr
11-
Projection::ColorizePointCloud(bool return_in_cam_frame) const {
10+
pcl::PointCloud<pcl::PointXYZRGB>::Ptr Projection::ColorizePointCloud() const {
1211
pcl::PointCloud<pcl::PointXYZRGB>::Ptr cloud_colored(
1312
new pcl::PointCloud<pcl::PointXYZRGB>);
1413
pcl::copyPointCloud(*cloud_in_camera_frame_, *cloud_colored);
@@ -56,7 +55,7 @@ pcl::PointCloud<pcl::PointXYZRGB>::Ptr
5655
}
5756

5857
pcl::PointCloud<beam_containers::PointBridge>::Ptr
59-
Projection::ColorizeMask(bool return_in_cam_frame) const {
58+
Projection::ColorizeMask() const {
6059
pcl::PointCloud<beam_containers::PointBridge>::Ptr defect_cloud(
6160
new pcl::PointCloud<beam_containers::PointBridge>);
6261

beam_colorize/src/RayTrace.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ void HitBehaviour(std::shared_ptr<cv::Mat> image,
1818
RayTrace::RayTrace() : Colorizer() {}
1919

2020
pcl::PointCloud<pcl::PointXYZRGB>::Ptr
21-
RayTrace::ColorizePointCloud(bool return_in_cam_frame) const {
21+
RayTrace::ColorizePointCloud() const {
2222
pcl::PointCloud<pcl::PointXYZRGB>::Ptr cloud_colored =
2323
std::make_shared<pcl::PointCloud<pcl::PointXYZRGB>>();
2424

@@ -75,7 +75,7 @@ std::tuple<pcl::PointCloud<pcl::PointXYZRGB>::Ptr, std::vector<int>>
7575
}
7676

7777
pcl::PointCloud<beam_containers::PointBridge>::Ptr
78-
RayTrace::ColorizeMask(bool return_in_cam_frame) const {
78+
RayTrace::ColorizeMask() const {
7979
pcl::PointCloud<beam_containers::PointBridge>::Ptr return_cloud;
8080
pcl::copyPointCloud(*cloud_in_camera_frame_, *return_cloud);
8181

0 commit comments

Comments
 (0)