fix naming

class name VSA_approximation to Variational_shape_approximation
This commit is contained in:
Lingjie Zhu 2018-05-25 09:42:51 +08:00
parent c203a3a38f
commit 183a092e6b
14 changed files with 21 additions and 21 deletions

View File

@ -14,7 +14,7 @@ typedef Kernel::FT FT;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_approx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
typedef CGAL::Timer Timer; typedef CGAL::Timer Timer;

View File

@ -13,7 +13,7 @@ typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_apporx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_apporx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
typedef CGAL::Timer Timer; typedef CGAL::Timer Timer;

View File

@ -40,7 +40,7 @@ and provides the list of parameters used in this package.
## Classes ## ## Classes ##
- `CGAL::VSA::L21_metric_vector_proxy` - `CGAL::VSA::L21_metric_vector_proxy`
- `CGAL::VSA::L2_metric_plane_proxy` - `CGAL::VSA::L2_metric_plane_proxy`
- `CGAL::VSA_approximation` - `CGAL::Variational_shape_approximation`
\todo add option to enforce guarantee of 2-manifold and oriented output mesh \todo add option to enforce guarantee of 2-manifold and oriented output mesh
\todo add option to smooth frontiers of the partition \todo add option to smooth frontiers of the partition

View File

@ -164,7 +164,7 @@ Free function with \ref namedparameters options.
- `CGAL::mesh_approximation()`: given a triangle mesh, approximate the geometry with default \f$ \mathcal{L}^{2,1} \f$ metric. - `CGAL::mesh_approximation()`: given a triangle mesh, approximate the geometry with default \f$ \mathcal{L}^{2,1} \f$ metric.
Class interface: Class interface:
- `CGAL::VSA_approximation`: allowing more customization of the proxy, metric and approximation process. - `CGAL::Variational_shape_approximation`: allowing more customization of the proxy, metric and approximation process.
The input of the algorithm is expected to be: The input of the algorithm is expected to be:
- Triangulated - Triangulated
@ -192,7 +192,7 @@ The free function can be used for retrieving the segmentation via proxy ids outp
\subsection sma_example3 Class Interface \subsection sma_example3 Class Interface
The class interface `CGAL::VSA_approximation` offers a flexible means to control of the algorithm. The following example uses the `CGAL::L2_metric_planar_proxy` to approximate the shape. The class interface `CGAL::Variational_shape_approximation` offers a flexible means to control of the algorithm. The following example uses the `CGAL::L2_metric_planar_proxy` to approximate the shape.
\cgalExample{Surface_mesh_approximation/vsa_class_interface_example.cpp} \cgalExample{Surface_mesh_approximation/vsa_class_interface_example.cpp}

View File

@ -9,7 +9,7 @@ typedef CGAL::Exact_predicates_inexact_constructions_kernel Kernel;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> Mesh_approximation; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> Mesh_approximation;
// L21 error metric // L21 error metric
typedef Mesh_approximation::Error_metric L21_metric; typedef Mesh_approximation::Error_metric L21_metric;

View File

@ -60,7 +60,7 @@ struct Compact_metric_point_proxy
const Facet_area_map area_pmap; const Facet_area_map area_pmap;
}; };
typedef CGAL::VSA_approximation< typedef CGAL::Variational_shape_approximation<
Polyhedron, Vertex_point_map, Compact_metric_point_proxy> Approximation; Polyhedron, Vertex_point_map, Compact_metric_point_proxy> Approximation;
int main() int main()

View File

@ -1,5 +1,5 @@
#ifndef CGAL_VSA_APPROXIMATION_H #ifndef CGAL_VARIATIONAL_SHAPE_APPROXIMATION_H
#define CGAL_VSA_APPROXIMATION_H #define CGAL_VARIATIONAL_SHAPE_APPROXIMATION_H
#include <CGAL/license/Surface_mesh_approximation.h> #include <CGAL/license/Surface_mesh_approximation.h>
@ -69,7 +69,7 @@ template <typename TriangleMesh,
typename ErrorMetricProxy = CGAL::Default, typename ErrorMetricProxy = CGAL::Default,
typename GeomTraits = CGAL::Default, typename GeomTraits = CGAL::Default,
typename Concurrency_tag = CGAL::Sequential_tag> typename Concurrency_tag = CGAL::Sequential_tag>
class VSA_approximation { class Variational_shape_approximation {
// public typedefs // public typedefs
public: public:
@ -278,7 +278,7 @@ public:
/*! /*!
* @brief %Default empty constructor. * @brief %Default empty constructor.
*/ */
VSA_approximation() : Variational_shape_approximation() :
m_ptm(NULL), m_ptm(NULL),
m_metric(NULL), m_metric(NULL),
m_average_edge_length(0.0) { m_average_edge_length(0.0) {
@ -297,7 +297,7 @@ public:
* @param tm `CGAL TriangleMesh` on which approximation operates. * @param tm `CGAL TriangleMesh` on which approximation operates.
* @param vpoint_map vertex point map of the mesh * @param vpoint_map vertex point map of the mesh
*/ */
VSA_approximation(const TriangleMesh &tm, const VertexPointMap &vpoint_map) : Variational_shape_approximation(const TriangleMesh &tm, const VertexPointMap &vpoint_map) :
m_ptm(&tm), m_ptm(&tm),
m_vpoint_map(vpoint_map), m_vpoint_map(vpoint_map),
m_metric(NULL), m_metric(NULL),
@ -319,7 +319,7 @@ public:
} }
/// @} /// @}
~VSA_approximation() { ~Variational_shape_approximation() {
if (m_ptm) { if (m_ptm) {
CGAL::internal::remove_property(m_vanchor_map, *(const_cast<TriangleMesh *>(m_ptm))); CGAL::internal::remove_property(m_vanchor_map, *(const_cast<TriangleMesh *>(m_ptm)));
CGAL::internal::remove_property(m_fproxy_map, *(const_cast<TriangleMesh *>(m_ptm))); CGAL::internal::remove_property(m_fproxy_map, *(const_cast<TriangleMesh *>(m_ptm)));
@ -2114,4 +2114,4 @@ private:
#undef CGAL_VSA_INVALID_TAG #undef CGAL_VSA_INVALID_TAG
#endif // CGAL_VSA_APPROXIMATION_H #endif // CGAL_VARIATIONAL_SHAPE_APPROXIMATION_H

View File

@ -113,7 +113,7 @@ bool mesh_approximation(const TriangleMesh &tm, const NamedParameters &np)
Vertex_point_map point_pmap = choose_param(get_param(np, sma_np::vertex_point), Vertex_point_map point_pmap = choose_param(get_param(np, sma_np::vertex_point),
get_property_map(vertex_point, const_cast<TriangleMesh &>(tm))); get_property_map(vertex_point, const_cast<TriangleMesh &>(tm)));
typedef CGAL::VSA_approximation<TriangleMesh, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<TriangleMesh, Vertex_point_map> L21_approx;
typedef typename L21_approx::Error_metric L21_metric; typedef typename L21_approx::Error_metric L21_metric;
const Approximation_verbose_level vl = choose_param( const Approximation_verbose_level vl = choose_param(

View File

@ -19,7 +19,7 @@ typedef boost::associative_property_map<std::map<Facet_handle, std::size_t> > Fa
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA::L2_metric_plane_proxy<Polyhedron> L2_metric_plane_proxy; typedef CGAL::VSA::L2_metric_plane_proxy<Polyhedron> L2_metric_plane_proxy;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map, L2_metric_plane_proxy> L2_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map, L2_metric_plane_proxy> L2_approx;
typedef L2_approx::Proxy Plane_proxy; typedef L2_approx::Proxy Plane_proxy;
/** /**

View File

@ -13,7 +13,7 @@ typedef Kernel::FT FT;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_approx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
bool test_shape(const char *file_name, const std::size_t target_num_proxies) bool test_shape(const char *file_name, const std::size_t target_num_proxies)

View File

@ -13,7 +13,7 @@ typedef Kernel::FT FT;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_approx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
bool check_strict_ordering(const std::vector<FT> &error) bool check_strict_ordering(const std::vector<FT> &error)

View File

@ -13,7 +13,7 @@ typedef Kernel::FT FT;
typedef CGAL::Polyhedron_3<Kernel> Polyhedron; typedef CGAL::Polyhedron_3<Kernel> Polyhedron;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_approx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
bool test_manifold(const char *file_name, const FT drop = FT(1e-8)) bool test_manifold(const char *file_name, const FT drop = FT(1e-8))

View File

@ -60,7 +60,7 @@ struct Compact_metric_point_proxy {
const Facet_area_map area_pmap; const Facet_area_map area_pmap;
}; };
typedef CGAL::VSA_approximation< typedef CGAL::Variational_shape_approximation<
Polyhedron, Vertex_point_map, Compact_metric_point_proxy> Compact_approx; Polyhedron, Vertex_point_map, Compact_metric_point_proxy> Compact_approx;
/** /**

View File

@ -23,7 +23,7 @@ typedef Polyhedron::Halfedge_handle Halfedge_handle;
typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map; typedef boost::property_map<Polyhedron, boost::vertex_point_t>::type Vertex_point_map;
typedef boost::associative_property_map<std::map<Facet_handle, std::size_t> > Facet_proxy_map; typedef boost::associative_property_map<std::map<Facet_handle, std::size_t> > Facet_proxy_map;
typedef CGAL::VSA_approximation<Polyhedron, Vertex_point_map> L21_approx; typedef CGAL::Variational_shape_approximation<Polyhedron, Vertex_point_map> L21_approx;
typedef L21_approx::Error_metric L21_metric; typedef L21_approx::Error_metric L21_metric;
typedef L21_approx::Proxy Plane_proxies; typedef L21_approx::Proxy Plane_proxies;