Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008 #ifndef POINTCLOUDMANAGER_H_
00009 #define POINTCLOUDMANAGER_H_
00010
00011 #include <vector>
00012 using std::vector;
00013
00014 #include "../geometry/Vertex.hpp"
00015 #include "../geometry/Normal.hpp"
00016 #include "../geometry/BoundingBox.hpp"
00017
00018 namespace lssr
00019 {
00020
00026 template<typename VertexT, typename NormalT>
00027 class PointCloudManager
00028 {
00029 public:
00037 virtual void getkClosestVertices(const VertexT &v,
00038 const size_t &k, vector<VertexT> &nb) = 0;
00039
00047 virtual void getkClosestNormals(const VertexT &n,
00048 const size_t &k, vector<NormalT> &nb) = 0;
00049
00053 virtual BoundingBox<VertexT>& getBoundingBox();
00054
00061 virtual VertexT getPoint(size_t index);
00062
00066 virtual size_t getNumPoints();
00067
00071 virtual const VertexT operator[](const size_t &index) const;
00072
00073 virtual float distance(VertexT v) = 0;
00074
00075 protected:
00076
00083 virtual void readFromFile(string filename);
00084
00086 float** m_points;
00087
00089 float** m_normals;
00090
00092 BoundingBox<VertexT> m_boundingBox;
00093
00094 size_t m_numPoints;
00095 };
00096
00097 }
00098
00099 #include "PointCloudManager.tcc"
00100
00101 #endif