Closest Point
Find the Closest Point on a mesh
include/Mesh.h
00001 #pragma once
00002 
00003 #include <iostream>
00004 #include <stdlib.h>
00005 #include <vector>
00006 #include <set>
00007 #include "Vector.h"
00008 #include "Face.h"
00009 #include "ply.h"
00010 
00011 using namespace std;
00012 using std::vector;
00013 using namespace math;
00014 
00015 class Mesh{
00016 
00017 private:
00018     vector<Vec3f> vertex_list;
00019     vector<Face> face_list;
00020     std::vector<set <int> > edgeList;
00021 
00022 public:
00023     int nverts,nfaces;
00024 
00025     Mesh(){};
00026     Mesh(const Mesh &obj);  
00027     ~Mesh(){};
00028     
00029     /*Getters and Setters for Mesh atributes*/
00030     inline vector<Vec3f> get_vertexList(){
00031         return vertex_list;
00032     }
00033 
00034     inline vector<Face> get_faceList(){
00035         return face_list;
00036     }
00037 
00038     inline std::vector<set <int> > get_edgeList(){
00039         return edgeList;
00040     }
00041     inline void set_edgeList(std::vector<set <int> > e){
00042         edgeList = e;
00043     }
00044 
00045     bool readPly(char* name);
00046 };
00047 
 All Classes