Go to the documentation of this file.
31 #if defined(FEVV_USE_CGAL) && \
32 (defined(USE_POLYHEDRON) || defined(USE_SURFACEMESH) || defined(USE_LCC))
33 #include "FEVV/DataStructures/DataStructures_cgal.h"
34 #ifdef WITH_GENERIC_READER
43 #if defined(FEVV_USE_OPENMESH) && defined(USE_OPENMESH)
45 #ifdef WITH_GENERIC_READER
51 #if defined(FEVV_USE_AIF) && defined(USE_AIF)
58 #ifdef WITH_GENERIC_READER
64 #ifdef WITH_GENERIC_READER
69 #ifdef WITH_NATIVE_READER
78 std::string mesh_type(
"Polyhedron");
81 #ifdef USE_SURFACEMESH
83 std::string mesh_type(
"Surface_mesh");
88 std::string mesh_type(
"LCC");
93 std::string mesh_type(
"Openmesh");
98 std::string mesh_type(
"AIF");
103 #ifdef WITH_GENERIC_READER
113 std::cout <<
"the mesh has " <<
num_vertices(m) <<
" vertice(s), "
115 #if !defined(USE_AIF)
116 << num_halfedges(m) <<
" halfedge(s), "
118 <<
num_faces(m) <<
" face(s)." << std::endl;
120 std::cout <<
"Done." << std::endl;
135 if(!(pm = in.
read(filename)))
137 std::cout <<
"failed";
147 std::cout <<
"failed";
152 std::ifstream in(filename);
155 std::cout <<
"Unable to read file " << filename << std::endl;
164 CGAL::load_off(m, in);
167 #endif // USE_OPENMESH
171 std::cout <<
"the mesh has " <<
num_vertices(m) <<
" vertice(s), "
173 #if !defined(USE_AIF)
174 << num_halfedges(m) <<
" halfedge(s), "
176 <<
num_faces(m) <<
" face(s)." << std::endl;
178 std::cout <<
"Done." << std::endl;
189 std::cout <<
"Usage: " << argv[0]
190 <<
" filename; filename being an off or vtk file." << std::endl;
194 std::cout <<
"Loading mesh using " <<
reader_type <<
" and " << mesh_type
boost::graph_traits< FEVV::DataStructures::AIF::AIFMesh >::vertices_size_type num_vertices(const FEVV::DataStructures::AIF::AIFMesh &sm)
Returns an upper bound of the number of vertices of the mesh.
FEVV::DataStructures::AIF::AIFMeshReader::ptr_output MeshAIFPtr
CGAL::Linear_cell_complex_for_combinatorial_map< 2, 3, CGALLCCTraits, CGALItem > MeshLCC
ptr_output read(const std::string &filePath)
int main(int narg, char **argv)
CGAL::Surface_mesh< CGALPoint > MeshSurface
std::map< std::string, boost::any > PMapsContainer
boost::graph_traits< FEVV::DataStructures::AIF::AIFMesh >::faces_size_type num_faces(const FEVV::DataStructures::AIF::AIFMesh &sm)
Returns an upper bound of the number of faces of the graph.
void load_mesh(std::string filename)
void read_mesh(const std::string &filename, FEVV::CGALPointSet &g, PMapsContainer &pmaps, bool=false)
Load mesh from file.
boost::graph_traits< FEVV::DataStructures::AIF::AIFMesh >::edges_size_type num_edges(const FEVV::DataStructures::AIF::AIFMesh &sm)
Returns an upper bound of the number of edges of the graph.
std::string reader_type("unkonwn reader")
AIFMeshReader reader_type
OpenMesh::PolyMesh_ArrayKernelT< MyTraits > MeshOpenMesh
This class represents an AIF structure. AIF structure can deal with both manifold and non-manifold su...
This class represents an AIFMesh object reader. An AIFMeshReader reads a mesh file (....
CGAL::Polyhedron_3< CGALKernel, CGAL::Polyhedron_items_with_id_3 > MeshPolyhedron
FEVV::DataStructures::AIF::AIFMesh MeshAIF