Point Cloud Library (PCL)
1.11.1-dev
|
49 template <
typename DataType>
80 using Type =
unsigned short;
87 using Type =
unsigned char;
108 template <
class DataType,
unsigned Dimension>
112 using Ptr = shared_ptr<IntegralImage2D<DataType, Dimension>>;
113 using ConstPtr = shared_ptr<const IntegralImage2D<DataType, Dimension>>;
115 using ElementType = Eigen::Matrix<typename IntegralImageTypeTraits<DataType>::IntegralType, Dimension, 1>;
122 first_order_integral_image_ (),
123 second_order_integral_image_ (),
126 compute_second_order_integral_images_ (compute_second_order_integral_images)
149 unsigned width,
unsigned height,
unsigned element_stride,
unsigned row_stride);
158 getFirstOrderSum (
unsigned start_x,
unsigned start_y,
unsigned width,
unsigned height)
const;
167 getFirstOrderSumSE (
unsigned start_x,
unsigned start_y,
unsigned end_x,
unsigned end_y)
const;
176 getSecondOrderSum (
unsigned start_x,
unsigned start_y,
unsigned width,
unsigned height)
const;
185 getSecondOrderSumSE (
unsigned start_x,
unsigned start_y,
unsigned end_x,
unsigned end_y)
const;
206 using InputType = Eigen::Matrix<typename IntegralImageTypeTraits<DataType>::Type, Dimension, 1>;
214 computeIntegralImages (
const DataType * data,
unsigned row_stride,
unsigned element_stride);
216 std::vector<ElementType, Eigen::aligned_allocator<ElementType> > first_order_integral_image_;
217 std::vector<SecondOrderType, Eigen::aligned_allocator<SecondOrderType> > second_order_integral_image_;
218 std::vector<unsigned> finite_values_integral_image_;
226 bool compute_second_order_integral_images_;
232 template <
class DataType>
236 using Ptr = shared_ptr<IntegralImage2D<DataType, 1>>;
237 using ConstPtr = shared_ptr<const IntegralImage2D<DataType, 1>>;
247 first_order_integral_image_ (),
248 second_order_integral_image_ (),
250 width_ (1), height_ (1),
251 compute_second_order_integral_images_ (compute_second_order_integral_images)
268 unsigned width,
unsigned height,
unsigned element_stride,
unsigned row_stride);
277 getFirstOrderSum (
unsigned start_x,
unsigned start_y,
unsigned width,
unsigned height)
const;
286 getFirstOrderSumSE (
unsigned start_x,
unsigned start_y,
unsigned end_x,
unsigned end_y)
const;
295 getSecondOrderSum (
unsigned start_x,
unsigned start_y,
unsigned width,
unsigned height)
const;
304 getSecondOrderSumSE (
unsigned start_x,
unsigned start_y,
unsigned end_x,
unsigned end_y)
const;
333 computeIntegralImages (
const DataType * data,
unsigned row_stride,
unsigned element_stride);
335 std::vector<ElementType, Eigen::aligned_allocator<ElementType> > first_order_integral_image_;
336 std::vector<SecondOrderType, Eigen::aligned_allocator<SecondOrderType> > second_order_integral_image_;
337 std::vector<unsigned> finite_values_integral_image_;
345 bool compute_second_order_integral_images_;
349 #include <pcl/features/impl/integral_image2D.hpp>
Determines an integral image representation for a given organized data array.
unsigned getFiniteElementsCountSE(unsigned start_x, unsigned start_y, unsigned end_x, unsigned end_y) const
Compute the number of finite elements within a given rectangle.
void setSecondOrderComputation(bool compute_second_order_integral_images)
sets the computation for second order integral images on or off.
typename IntegralImageTypeTraits< DataType >::IntegralType ElementType
unsigned long IntegralType
unsigned long IntegralType
ElementType getFirstOrderSumSE(unsigned start_x, unsigned start_y, unsigned end_x, unsigned end_y) const
Compute the first order sum within a given rectangle.
shared_ptr< const IntegralImage2D< DataType, 1 > > ConstPtr
virtual ~IntegralImage2D()
Destructor.
static const unsigned second_order_size
IntegralImage2D(bool compute_second_order_integral_images)
Constructor for an Integral Image.
unsigned int IntegralType
ElementType getFirstOrderSum(unsigned start_x, unsigned start_y, unsigned width, unsigned height) const
Compute the first order sum within a given rectangle.
shared_ptr< const IntegralImage2D< float, Dimension > > ConstPtr
unsigned getFiniteElementsCount(unsigned start_x, unsigned start_y, unsigned width, unsigned height) const
Compute the number of finite elements within a given rectangle.
virtual ~IntegralImage2D()
Destructor.
shared_ptr< IntegralImage2D< float, Dimension > > Ptr
Eigen::Matrix< typename IntegralImageTypeTraits< float >::IntegralType, Dimension, 1 > ElementType
typename IntegralImageTypeTraits< DataType >::IntegralType SecondOrderType
Eigen::Matrix< typename IntegralImageTypeTraits< float >::IntegralType, second_order_size, 1 > SecondOrderType
IntegralImage2D(bool compute_second_order_integral_images)
Constructor for an Integral Image.
SecondOrderType getSecondOrderSumSE(unsigned start_x, unsigned start_y, unsigned end_x, unsigned end_y) const
Compute the second order sum within a given rectangle.
SecondOrderType getSecondOrderSum(unsigned start_x, unsigned start_y, unsigned width, unsigned height) const
Compute the second order sum within a given rectangle.
void setInput(const DataType *data, unsigned width, unsigned height, unsigned element_stride, unsigned row_stride)
Set the input data to compute the integral image for.
Defines functions, macros and traits for allocating and using memory.
shared_ptr< IntegralImage2D< DataType, 1 > > Ptr