MEPP2 Project
msdm2_surfacemesh.h
Go to the documentation of this file.
1 // Copyright (c) 2012-2019 University of Lyon and CNRS (France).
2 // All rights reserved.
3 //
4 // This file is part of MEPP2; you can redistribute it and/or modify
5 // it under the terms of the GNU General Public License as published
6 // by the Free Software Foundation; either version 3 of the License,
7 // or (at your option) any later version.
8 //
9 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
10 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
11 
12 #pragma once
13 
14 #include <CGAL/version_macros.h>
15 
16 #include <CGAL/Cartesian.h>
17 #include <CGAL/boost/graph/graph_traits_Surface_mesh.h>
18 
19 #include <boost/property_map/vector_property_map.hpp>
20 
21 #if defined _MSC_VER
22 #define WINDLL_EXPORT __declspec(dllexport)
23 #else
24 #define WINDLL_EXPORT
25 #endif
26 
27 namespace msdm2 {
28 
29 using CGALKernel = CGAL::Cartesian< double >;
30 using CGALPoint = CGALKernel::Point_3;
31 
32 using MeshT = CGAL::Surface_mesh< CGALPoint >;
34 
36  boost::property_map< MeshT, boost::vertex_index_t >::const_type;
37 using Msdm2MapT = boost::vector_property_map< double, VertexIndexMapT >;
38 
39 
50 void msdm2_surfacemesh(const MeshT &mesh_degraded, /* input */
51  const MeshT &mesh_original, /* input */
52  const int nb_levels, /* input */
53  double &msdm2_value, /* output */
54  Msdm2MapT &msdm2_pmap); /* output */
55 
56 } // namespace msdm2
msdm2
Definition: msdm2_surfacemesh.cpp:20
msdm2::VertexIndexMapT
boost::property_map< MeshT, boost::vertex_index_t >::const_type VertexIndexMapT
Definition: msdm2_surfacemesh.h:36
msdm2::CGALPoint
CGALKernel::Point_3 CGALPoint
Definition: msdm2_surfacemesh.h:30
msdm2::CGALKernel
CGAL::Cartesian< double > CGALKernel
Definition: msdm2_surfacemesh.h:29
msdm2::Msdm2MapT
boost::vector_property_map< double, VertexIndexMapT > Msdm2MapT
Definition: msdm2_surfacemesh.h:37
msdm2::msdm2_surfacemesh
void msdm2_surfacemesh(const MeshT &mesh_degraded, const MeshT &mesh_original, const int nb_levels, double &msdm2_value, Msdm2MapT &msdm2_pmap)
Computes the multiscale MSDM2 metric.
Definition: msdm2_surfacemesh.cpp:25
msdm2::vertex_descriptor
boost::graph_traits< MeshT >::vertex_descriptor vertex_descriptor
Definition: msdm2_surfacemesh.h:33
WINDLL_EXPORT
#define WINDLL_EXPORT
Definition: msdm2_surfacemesh.h:24
msdm2::MeshT
CGAL::Surface_mesh< CGALPoint > MeshT
Definition: msdm2_surfacemesh.h:32