I do not understand the difference between .h, .hpp and .cpp files in the Point Cloud Library. Here is an example with the bilateral filter, they say that:
- include/pcl/filters/bilateral.h - will contain all definitions;
- include/pcl/filters/impl/bilateral.hpp - will contain the templated implementations;
- src/bilateral.cpp - will contain the explicit template instantiations.
I understand the general concept of header file and implementation, but why are there two headers file? What's the difference between the templated implementation and the explicit template instantiation?
At this moment I am working with the Kmeans class and the .hpp is not used, instead they just have the implementation in a .cpp file and they include an .h file. Why? Moreover, in kmeans.h file they give the implementation of some public member functions, not just setters and getters. I can't find the rationale behind this code.
Thank you!