Fix voronoi_covariance_3 and HalfedgeDS_vector

This commit is contained in:
Andreas Fabri 2018-03-29 10:43:52 +01:00
parent 7d2e7dfedb
commit 643aaf2dcf
5 changed files with 18 additions and 16 deletions

View File

@ -64,8 +64,6 @@ namespace CGAL
typedef typename boost::graph_traits<Polyhedron_dual>::face_descriptor
Facet_const_handle;
typedef typename boost::graph_traits<Polyhedron_dual>::face_iterator
Facet_const_iterator;
typedef typename boost::graph_traits<Polyhedron_dual>::vertex_descriptor
Vertex_const_descriptor;
typedef typename boost::graph_traits<Polyhedron_dual>::halfedge_descriptor

View File

@ -137,9 +137,9 @@ public:
typedef typename Halfedge_list::const_iterator Halfedge_const_iterator;
typedef N_step_adaptor_derived<Halfedge_iterator, 2>
Edge_iterator;
Edge_iterator;
typedef N_step_adaptor_derived<Halfedge_const_iterator, 2>
Edge_const_iterator;
Edge_const_iterator;
typedef In_place_list<Face,false,Face_allocator> Face_list;
typedef typename Face_list::iterator Face_handle;

View File

@ -32,6 +32,7 @@
#include <CGAL/basic.h>
#include <CGAL/memory.h>
#include <CGAL/HalfedgeDS_items_decorator.h>
#include <CGAL/N_step_adaptor_derived.h>
#include <algorithm>
#include <vector>
#include <map>
@ -75,7 +76,7 @@ public:
typedef typename Face_alloc_rebind::other Face_allocator;
#ifdef CGAL__HALFEDGEDS_USE_INTERNAL_VECTOR
typedef internal::vector<Vertex, Vertex_allocator> Vertex_vector;
typedef internal::vector<Vertex, Vertex_allocator> Vertex_vector;
typedef typename Vertex_vector::iterator Vertex_I;
typedef typename Vertex_vector::const_iterator Vertex_CI;
typedef typename Vertex_vector::iterator Vertex_iterator;
@ -87,7 +88,12 @@ public:
typedef typename Halfedge_vector::iterator Halfedge_iterator;
typedef typename Halfedge_vector::const_iterator Halfedge_const_iterator;
typedef internal::vector<Face, Face_allocator> Face_vector;
typedef N_step_adaptor_derived<Halfedge_iterator, 2>
Edge_iterator;
typedef N_step_adaptor_derived<Halfedge_const_iterator, 2>
Edge_const_iterator;
typedef internal::vector<Face, Face_allocator> Face_vector;
typedef typename Face_vector::iterator Face_I;
typedef typename Face_vector::const_iterator Face_CI;
typedef typename Face_vector::iterator Face_iterator;

View File

@ -37,6 +37,8 @@
#include <CGAL/Convex_hull_3/dual/halfspace_intersection_3.h>
#endif
#include <CGAL/HalfedgeDS_default.h>
/// \cond SKIP_IN_MANUAL
namespace CGAL {
@ -144,7 +146,7 @@ namespace CGAL {
typedef typename K::Plane_3 Plane;
typedef typename K::Point_3 Point;
typedef typename K::Vector_3 Vector;
typedef typename CGAL::Convex_hull_traits_3<K> Traits;
typedef typename CGAL::Convex_hull_traits_3<K, HalfedgeDS_default<K,HalfedgeDS_items_3> > Traits;
typedef typename Traits::Polygon_mesh Polyhedron;
std::list<Vertex_handle> vertices;
@ -176,16 +178,15 @@ namespace CGAL {
boost::make_optional(Point(CGAL::ORIGIN)));
// apply f to the triangles on the boundary of P
for (typename Polyhedron::Facet_iterator it = P.facets_begin();
it != P.facets_end(); ++it)
BOOST_FOREACH(typename boost::graph_traits<Polyhedron>::face_descriptor fd, faces(P))
{
typename Polyhedron::Halfedge_around_facet_circulator
h0 = it->facet_begin(), hf = h0--, hs = cpp11::next(hf);
Halfedge_around_face_circulator<Polyhedron>
h0(halfedge(fd,P),P), hf = h0--, hs = cpp11::next(hf);
while(hs != h0)
{
f (h0->vertex()->point(), hf->vertex()->point(),
hs->vertex()->point());
f ((*h0)->vertex()->point(), (*hf)->vertex()->point(),
(*hs)->vertex()->point());
++hs; ++hf;
}
}

View File

@ -9,9 +9,6 @@
//----------------------------------------------------------
// normal_estimation_test points1.xyz points2.xyz...
// With iterator debugging this testsuite takes to long and the process gets killed
//#define _HAS_ITERATOR_DEBUGGING 0
// CGAL
#include <CGAL/Simple_cartesian.h>
#include <CGAL/Timer.h>