00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00040 #ifndef PCL_RANGE_IMAGE_PLANAR_H_
00041 #define PCL_RANGE_IMAGE_PLANAR_H_
00042
00043 #include <pcl/range_image/range_image.h>
00044
00045 namespace pcl
00046 {
00053 class RangeImagePlanar : public RangeImage
00054 {
00055 public:
00056
00057 typedef RangeImage BaseClass;
00058
00059
00061 RangeImagePlanar ();
00063 ~RangeImagePlanar ();
00064
00067 virtual RangeImage* getNew() const { return new RangeImagePlanar; }
00068
00069
00080 void
00081 setDisparityImage (const float* disparity_image, int di_width, int di_height,
00082 float focal_length, float base_line, float desired_angular_resolution=-1);
00083
00096 void
00097 setDepthImage (const float* depth_image, int di_width, int di_height, float di_center_x, float di_center_y,
00098 float di_focal_length_x, float di_focal_length_y, float desired_angular_resolution=-1);
00112 template <typename PointCloudType> void
00113 createFromPointCloudWithFixedSize (const PointCloudType& point_cloud,
00114 int di_width, int di_height, float di_center_x, float di_center_y,
00115 float di_focal_length_x, float di_focal_length_y,
00116 const Eigen::Affine3f& sensor_pose,
00117 CoordinateFrame coordinate_frame=CAMERA_FRAME, float noise_level=0.0f,
00118 float min_range=0.0f);
00119
00120
00121 using RangeImage::calculate3DPoint;
00122 using RangeImage::getImagePoint;
00123
00131 virtual inline void
00132 calculate3DPoint (float image_x, float image_y, float range, Eigen::Vector3f& point) const;
00133
00141 virtual inline void
00142 getImagePoint (const Eigen::Vector3f& point, float& image_x, float& image_y, float& range) const;
00143
00157 virtual void
00158 getSubImage (int sub_image_image_offset_x, int sub_image_image_offset_y, int sub_image_width,
00159 int sub_image_height, int combine_pixels, RangeImage& sub_image) const;
00160
00162 virtual void
00163 getHalfImage(RangeImage& half_image) const;
00164
00165 protected:
00166 float focal_length_x_, focal_length_y_;
00167 float focal_length_x_reciprocal_, focal_length_y_reciprocal_;
00168 float center_x_, center_y_;
00169 };
00170 }
00171
00172
00173 #include "pcl/range_image/range_image_planar.hpp"
00174
00175 #endif //#ifndef PCL_RANGE_IMAGE_H_