mirror of https://github.com/CGAL/cgal
Move internal class from Polyhedron to BGL
This commit is contained in:
parent
8f8cbbc84e
commit
b918ab4ba7
|
|
@ -241,6 +241,46 @@ void init_halfedge_indices(PolygonMesh& pm, HalfedgeIndexMap hid)
|
|||
|
||||
} //namespace helpers
|
||||
|
||||
namespace internal {
|
||||
|
||||
template<typename Polyhedron, typename Handle>
|
||||
struct Index_accessor
|
||||
: boost::put_get_helper< std::size_t&, Index_accessor<Polyhedron,Handle> >
|
||||
{
|
||||
typedef boost::lvalue_property_map_tag category;
|
||||
typedef std::size_t& reference;
|
||||
typedef std::size_t value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h->id(); }
|
||||
};
|
||||
|
||||
template<typename Handle>
|
||||
struct Edge_index_accessor
|
||||
: boost::put_get_helper< std::size_t, Edge_index_accessor<Handle> >
|
||||
{
|
||||
typedef boost::readable_property_map_tag category;
|
||||
typedef std::size_t reference;
|
||||
typedef std::size_t value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h.id(); }
|
||||
};
|
||||
|
||||
template<typename Handle, typename ValueType, typename Reference>
|
||||
struct Point_accessor
|
||||
: boost::put_get_helper< Reference, Point_accessor<Handle, ValueType, Reference> >
|
||||
{
|
||||
typedef boost::lvalue_property_map_tag category;
|
||||
typedef Reference reference;
|
||||
typedef ValueType value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h->point(); }
|
||||
};
|
||||
|
||||
} // namespace internal
|
||||
|
||||
} // namespace CGAL
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -11,10 +11,6 @@
|
|||
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
|
||||
|
||||
#include <CGAL/Polyhedron_items_with_id_3.h>
|
||||
#include <CGAL/IO/Polyhedron_iostream.h>
|
||||
|
||||
#include <CGAL/boost/graph/graph_traits_Polyhedron_3.h>
|
||||
|
||||
#include <CGAL/Linear_cell_complex_for_bgl_combinatorial_map_helper.h>
|
||||
#include <CGAL/boost/graph/graph_traits_Linear_cell_complex_for_combinatorial_map.h>
|
||||
#include <CGAL/boost/graph/properties_Linear_cell_complex_for_combinatorial_map.h>
|
||||
|
|
@ -22,9 +18,6 @@
|
|||
#ifdef CGAL_USE_SURFACE_MESH
|
||||
#include <CGAL/Surface_mesh.h>
|
||||
#include <CGAL/Surface_mesh/IO.h>
|
||||
|
||||
#include <CGAL/boost/graph/graph_traits_Surface_mesh.h>
|
||||
#include <CGAL/boost/graph/properties_Surface_mesh.h>
|
||||
#endif
|
||||
|
||||
#include <CGAL/boost/graph/io.h>
|
||||
|
|
|
|||
|
|
@ -18,13 +18,15 @@
|
|||
//
|
||||
// Author(s) : Guillaume Damiand <guillaume.damiand@liris.cnrs.fr>
|
||||
//
|
||||
|
||||
|
||||
#ifndef CGAL_BOOST_GRAPH_PROPERTIES_LINEAR_CELL_COMPLEX_FOR_COMBINATORIAL_MAP_H
|
||||
#define CGAL_BOOST_GRAPH_PROPERTIES_LINEAR_CELL_COMPLEX_FOR_COMBINATORIAL_MAP_H
|
||||
|
||||
#include <CGAL/boost/graph/properties.h>
|
||||
#include <CGAL/Linear_cell_complex_for_combinatorial_map.h>
|
||||
#include <CGAL/Unique_hash_map.h>
|
||||
#include <CGAL/boost/graph/properties_Polyhedron_3.h>
|
||||
|
||||
|
||||
#define CGAL_LCC_ARGS unsigned int d_, unsigned int ambient_dim, \
|
||||
class Traits_, \
|
||||
|
|
|
|||
|
|
@ -103,42 +103,6 @@ struct Wrap_squared
|
|||
}
|
||||
};
|
||||
|
||||
template<typename Polyhedron, typename Handle>
|
||||
struct Index_accessor
|
||||
: boost::put_get_helper< std::size_t&, Index_accessor<Polyhedron,Handle> >
|
||||
{
|
||||
typedef boost::lvalue_property_map_tag category;
|
||||
typedef std::size_t& reference;
|
||||
typedef std::size_t value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h->id(); }
|
||||
};
|
||||
|
||||
template<typename Handle>
|
||||
struct Edge_index_accessor
|
||||
: boost::put_get_helper< std::size_t, Edge_index_accessor<Handle> >
|
||||
{
|
||||
typedef boost::readable_property_map_tag category;
|
||||
typedef std::size_t reference;
|
||||
typedef std::size_t value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h.id(); }
|
||||
};
|
||||
|
||||
template<typename Handle, typename ValueType, typename Reference>
|
||||
struct Point_accessor
|
||||
: boost::put_get_helper< Reference, Point_accessor<Handle, ValueType, Reference> >
|
||||
{
|
||||
typedef boost::lvalue_property_map_tag category;
|
||||
typedef Reference reference;
|
||||
typedef ValueType value_type;
|
||||
typedef Handle key_type;
|
||||
|
||||
reference operator[](Handle h) const { return h->point(); }
|
||||
};
|
||||
|
||||
} // internal
|
||||
|
||||
// the tag we dispatch on from property_map<G, Property>
|
||||
|
|
|
|||
Loading…
Reference in New Issue