I'm working with PCL (Point Cloud Library). I've made a class (myPCL_SI
) that inherits from a PCL template class (pcl::SpinImageEstimation
). I've created an other normal class (myPCL
) that creates a myPCL_SI
object.
I do this because I need to access to a protected method from pcl::SpinIMageEstimation
. If someone knows a better solution, please say me.
Ok, my problem is that when I try to create a myPCL_SI
object, the compiler give me this error:
error: ‘spinImage’ was not declared in this scope
error: template argument 1 is invalid
error: template argument 3 is invalid
My code is this one:
myPCL class (only my method)
void myPCL::calcSpinImage(){
myPCL_SI<pcl::PointXYZ, pcl::Normal, pcl::Histogram<153>> spinImage;
// doing more things...
}
myPCL_SI class (header)
#ifndef MYPCL_SI_H
#define MYPCL_SI_H
// a lot of includes...
using namespace pcl;
template <typename PointInT, typename PointNT, typename PointOutT>
class myPCL_SI : public SpinImageEstimation<PointInT, PointNT, PointOutT>
{
public:
myPCL_SI();
void compute(PointCloud<PointXYZ>::Ptr cloud);
};
#include "mypcl_si.cpp"
#endif // MYPCL_SI_H
myPCL_SI class (impl)
template <typename PointInT, typename PointNT, typename PointOutT>
myPCL_SI<PointInT, PointNT, PointOutT>::myPCL_SI()
{
}
Thanks a lot! :D