46 #ifndef ORR_OCTREE_ZPROJECTION_H_
47 #define ORR_OCTREE_ZPROJECTION_H_
49 #include "orr_octree.h"
50 #include <pcl/pcl_exports.h>
75 z1 ()
const {
return z1_;}
78 z2 ()
const {
return z2_;}
93 : nodes_ (compare_nodes_z), x_ (x), y_ (y)
106 get_nodes (){
return nodes_;}
127 build (
const ORROctree& input,
float eps_front,
float eps_back);
135 x =
static_cast<int> ((p[0] - bounds_[0])*inv_pixel_size_);
136 y =
static_cast<int> ((p[1] - bounds_[2])*inv_pixel_size_);
142 int x, y; this->getPixelCoordinates (p, x, y);
144 if ( x < 0 || x >= num_pixels_x_ )
return (NULL);
145 if ( y < 0 || y >= num_pixels_y_ )
return (NULL);
147 return (pixels_[x][y]);
153 int x, y; this->getPixelCoordinates (p, x, y);
155 if ( x < 0 || x >= num_pixels_x_ )
return (NULL);
156 if ( y < 0 || y >= num_pixels_y_ )
return (NULL);
158 return (pixels_[x][y]);
162 getOctreeNodes (
const float* p)
const
164 int x, y; this->getPixelCoordinates (p, x, y);
166 if ( x < 0 || x >= num_pixels_x_ )
return (NULL);
167 if ( y < 0 || y >= num_pixels_y_ )
return (NULL);
172 return (&sets_[x][y]->get_nodes ());
175 inline std::list<Pixel*>&
181 return pixels_[i][j];
200 num_x = num_pixels_x_;
201 num_y = num_pixels_y_;
205 float pixel_size_, inv_pixel_size_, bounds_[4], extent_x_, extent_y_;