Go to the documentation of this file.
17 #define CGAL_USE_OM_POINTS
18 #include <CGAL/boost/graph/graph_traits_PolyMesh_ArrayKernelT.h>
19 #include <CGAL/boost/graph/properties_PolyMesh_ArrayKernelT.h>
26 #include <OpenMesh/Core/IO/MeshIO.hh>
36 typedef OpenMesh::PolyMesh_ArrayKernelT< MyTraitsDouble >
45 typedef OMMesh HalfedgeGraph;
47 std::cout <<
"Asking to Curvature mesh ! " << std::endl;
49 auto pm =
get(boost::vertex_point, *mesh);
72 double min_nrm_min_curvature, max_nrm_min_curvature, min_nrm_max_curvature,
73 max_nrm_max_curvature;
75 bool value_is_geod =
false;
76 double value_radius = 0.001;
85 min_nrm_min_curvature,
86 max_nrm_min_curvature,
87 min_nrm_max_curvature,
88 max_nrm_max_curvature);
92 std::cout <<
"Curvature mesh, isGeod: " << value_is_geod
93 <<
" - radius: " << value_radius <<
"." << std::endl;
99 main(
int narg,
char **argv)
103 std::cout <<
"Usage: " << argv[0] <<
" mesh_filename" << std::endl;
106 std::string filename(argv[1]);
112 std::cout <<
"Failed to read file." << std::endl;
120 std::cout <<
"Done." << std::endl;
int main(int narg, char **argv)
void curvature(OMMesh *mesh)
void calculate_curvature(const HalfedgeGraph &g, VertexCurvatureMap &v_cm, const PointMap &pm, const FaceNormalMap &f_nm, bool is_geod, double radius, double &min_nrm_min_curvature, double &max_nrm_min_curvature, double &min_nrm_max_curvature, double &max_nrm_max_curvature, const GeometryTraits >)
Calculate the curvature for a mesh.
void read_mesh(const std::string &filename, FEVV::CGALPointSet &g, PMapsContainer &pmaps, bool=false)
Load mesh from file.
Vertex_pmap_traits< MeshT, ValueT >::pmap_type make_vertex_property_map(const MeshT &m)
void calculate_face_normals(const HalfedgeGraph &g, const PointMap &pm, FaceNormalMap fnm, const GeometryTraits >)
Calculate "some" normal of all the faces of the considered mesh and populate the argument provided Fa...
OpenMesh::PolyMesh_ArrayKernelT< MyTraitsDouble > OMMesh
boost::property_map< FEVV::DataStructures::AIF::AIFMesh, boost::vertex_index_t >::const_type get(const boost::vertex_index_t &, const FEVV::DataStructures::AIF::AIFMesh &)
Returns the vertex index property map of the mesh.
PMap_traits< PropertyT, MeshT >::pmap_type make_property_map(PropertyT, const MeshT &m)