mirror of https://github.com/CGAL/cgal
- replace "assert" by "CGAL_triangulation_assertion"
- in Regular_triangulation_euclidean_traits_2<R,W> changed the default for W from R::FT to R::FT
This commit is contained in:
parent
217c5a41e7
commit
d3d66c3073
|
|
@ -1,6 +1,10 @@
|
|||
Package triangulation: provides triangulations Delaunay triangulations,
|
||||
constrained and regular triangulations with tests and examples.
|
||||
|
||||
Ver 5.22 (??)
|
||||
- replace "assert" by "CGAL_triangulation_assertion"
|
||||
- in Regular_triangulation_euclidean_traits_2<R,W>
|
||||
changed the default for W from R::FT to R::FT
|
||||
|
||||
Ver 5.21 (14/9/01)
|
||||
- added member functions to query the constraint hierarchy
|
||||
|
|
|
|||
|
|
@ -679,7 +679,7 @@ find_intersected_faces(Vertex_handle va,
|
|||
Point a=va->point(), b=vb->point();
|
||||
Line_face_circulator current_face=line_walk(vaa->point(),b, vaa->face());
|
||||
int ind=current_face->index(vaa);
|
||||
assert( !current_face->is_constrained(ind));
|
||||
CGAL_triangulation_assertion( !current_face->is_constrained(ind));
|
||||
Face_handle lf= current_face->neighbor(ccw(ind));
|
||||
Face_handle rf= current_face->neighbor(cw(ind));
|
||||
Orientation orient;
|
||||
|
|
@ -716,7 +716,7 @@ find_intersected_faces(Vertex_handle va,
|
|||
i2 = ccw(ind); //index of non intersected edge of current_face
|
||||
}
|
||||
|
||||
assert( !current_face->is_constrained(i1));
|
||||
CGAL_triangulation_assertion( !current_face->is_constrained(i1));
|
||||
lf= current_face->neighbor(i2);
|
||||
intersected_faces.push_front(current_face);
|
||||
if (orient == LEFTTURN)
|
||||
|
|
|
|||
|
|
@ -413,7 +413,7 @@ intersect(Face_handle f, int i,
|
|||
std::cerr << " sorry, this triangulation does not deal "
|
||||
<< std::endl
|
||||
<< " intersecting constraints" << std::endl;
|
||||
assert(false);
|
||||
CGAL_triangulation_assertion(false);
|
||||
return Vertex_handle();
|
||||
}
|
||||
|
||||
|
|
@ -434,8 +434,8 @@ intersect(Face_handle f, int i,
|
|||
Vertex_handle vcc, vdd;
|
||||
vcc = f->vertex(cw(i));
|
||||
vdd = f->vertex(ccw(i));
|
||||
assert(hierarchy.enclosing_constraint(vcc,vdd,vc,vd));
|
||||
assert(hierarchy.enclosing_constraint(vaa,vbb,va,vb));
|
||||
CGAL_triangulation_assertion(hierarchy.enclosing_constraint(vcc,vdd,vc,vd));
|
||||
CGAL_triangulation_assertion(hierarchy.enclosing_constraint(vaa,vbb,va,vb));
|
||||
|
||||
Point pi; //creator for point is required here
|
||||
Object result;
|
||||
|
|
@ -443,7 +443,7 @@ intersect(Face_handle f, int i,
|
|||
compute_intersection=geom_traits().intersect_2_object();
|
||||
result = compute_intersection(Segment(vc->point(),vd->point()),
|
||||
Segment(va->point(),vb->point()));
|
||||
assert(assign(pi, result));
|
||||
CGAL_triangulation_assertion(assign(pi, result));
|
||||
|
||||
Vertex_handle vi = insert(pi, EDGE, f, i);
|
||||
return vi;
|
||||
|
|
@ -470,7 +470,7 @@ intersect(Face_handle f, int i,
|
|||
Segment(vaa->point(),vbb->point()));
|
||||
bool intersection = assign(pi, result);
|
||||
if (!intersection) {
|
||||
assert(false); // what can I do here? TODO
|
||||
CGAL_triangulation_assertion(false); // what can I do here? TODO
|
||||
}
|
||||
|
||||
remove_constraint(f, i);
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ public:
|
|||
|
||||
void remove_flat(Face_handle fh)
|
||||
{
|
||||
assert((*fh).vertex(1) == (*fh).vertex(2));
|
||||
CGAL_triangulation_precondition((*fh).vertex(1) == (*fh).vertex(2));
|
||||
Face_handle f2= (*fh).neighbor(2);
|
||||
Face_handle f1= (*fh).neighbor(1);
|
||||
if ( !f2.is_null()) { (*f2).set_neighbor( (*f2).index(fh), f1);}
|
||||
|
|
@ -396,7 +396,7 @@ build_triangulation()
|
|||
|
||||
// delete event from event_queue
|
||||
out= (*event).second;
|
||||
assert( (*out).empty());
|
||||
CGAL_triangulation_assertion( (*out).empty());
|
||||
delete out; //delete la liste out
|
||||
queue.erase(event);
|
||||
|
||||
|
|
@ -404,7 +404,7 @@ build_triangulation()
|
|||
// make inifinite vertex, infinite faces
|
||||
// at this stage status is empty
|
||||
// and the lists of upper_chain correspond to the convex hull
|
||||
assert( status.empty());
|
||||
CGAL_triangulation_assertion( status.empty());
|
||||
//the_vertex = set_infinite_faces();
|
||||
set_infinite_faces();
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -198,7 +198,7 @@ demo_build_triangulation(Window_stream& W)
|
|||
|
||||
// delete event from event_queue
|
||||
out= (*event).second;
|
||||
assert( (*out).empty());
|
||||
CGAL_triangulation_assertion( (*out).empty());
|
||||
delete out;
|
||||
queue.erase(event);
|
||||
//delete la liste out
|
||||
|
|
@ -206,7 +206,7 @@ demo_build_triangulation(Window_stream& W)
|
|||
// make inifinite vertex, infinite faces
|
||||
// at this stage status is empty
|
||||
// and the lists of upper_chain correspond to the convex hull
|
||||
assert( status.empty());
|
||||
CGAL_triangulation_assertion( status.empty());
|
||||
the_vertex = set_infinite_faces();
|
||||
|
||||
return;
|
||||
|
|
|
|||
|
|
@ -238,7 +238,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
context(T va, T vb)
|
||||
{
|
||||
H_context_iterator hcit, past;
|
||||
assert(get_contexts(va,vb, hcit ,past));
|
||||
CGAL_triangulation_assertion(get_contexts(va,vb, hcit ,past));
|
||||
return *hcit;
|
||||
}
|
||||
|
||||
|
|
@ -248,7 +248,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
number_of_enclosing_constraints(T va, T vb)
|
||||
{
|
||||
H_context_list* hcl;
|
||||
assert(get_contexts(va,vb,hcl));
|
||||
CGAL_triangulation_assertion(get_contexts(va,vb,hcl));
|
||||
return hcl->size();
|
||||
}
|
||||
|
||||
|
|
@ -258,7 +258,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
contexts_begin(T va, T vb)
|
||||
{
|
||||
H_context_iterator first, last;
|
||||
assert( get_contexts(va,vb,first,last));
|
||||
CGAL_triangulation_assertion( get_contexts(va,vb,first,last));
|
||||
return first;
|
||||
}
|
||||
|
||||
|
|
@ -268,7 +268,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
contexts_end(T va, T vb)
|
||||
{
|
||||
H_context_iterator first, last;
|
||||
assert( get_contexts(va,vb,first,last));
|
||||
CGAL_triangulation_assertion( get_contexts(va,vb,first,last));
|
||||
return last;
|
||||
}
|
||||
|
||||
|
|
@ -278,7 +278,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
vertices_in_constraint_begin(T va, T vb)
|
||||
{
|
||||
H_c_iterator cit = c_to_sc_map.find(make_edge(va,vb));
|
||||
assert( cit != c_to_sc_map.end());
|
||||
CGAL_triangulation_assertion( cit != c_to_sc_map.end());
|
||||
return cit->second->begin();
|
||||
}
|
||||
|
||||
|
|
@ -288,7 +288,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
vertices_in_constraint_end(T va, T vb)
|
||||
{
|
||||
H_c_iterator cit = c_to_sc_map.find(make_edge(va,vb));
|
||||
assert( cit != c_to_sc_map.end());
|
||||
CGAL_triangulation_assertion( cit != c_to_sc_map.end());
|
||||
return cit->second->end();
|
||||
}
|
||||
|
||||
|
|
@ -375,7 +375,7 @@ next_along_sc(T va, T vb, T& w) const
|
|||
// find the next vertex after vb along any enclosing constrained
|
||||
// return false if there is no ....
|
||||
H_context_iterator ctxtit, past;
|
||||
assert(get_contexts(va, vb, ctxtit, past));
|
||||
CGAL_triangulation_assertion(get_contexts(va, vb, ctxtit, past));
|
||||
|
||||
H_vertex_it pos;
|
||||
for( ; ctxtit != past; ctxtit++){
|
||||
|
|
@ -406,8 +406,8 @@ remove_Steiner(T v, T va, T vb)
|
|||
|
||||
H_context_list* hcl1;
|
||||
H_context_list* hcl2;
|
||||
assert(get_contexts(va,v,hcl1));
|
||||
assert(get_contexts(v,vb,hcl2));
|
||||
CGAL_triangulation_assertion(get_contexts(va,v,hcl1));
|
||||
CGAL_triangulation_assertion(get_contexts(v,vb,hcl2));
|
||||
|
||||
H_vertex_it pos;
|
||||
for(H_context_iterator ctit=hcl1->begin(); ctit != hcl1->end(); ctit++){
|
||||
|
|
@ -441,7 +441,7 @@ void
|
|||
Constraint_hierarchy_2<T,Data>::
|
||||
add_Steiner(T va, T vb, T vc){
|
||||
H_context_list* hcl;
|
||||
assert(get_contexts(va,vb,hcl));
|
||||
CGAL_triangulation_assertion(get_contexts(va,vb,hcl));
|
||||
|
||||
H_context_list* hcl2 = new H_context_list;
|
||||
|
||||
|
|
@ -547,7 +547,7 @@ Constraint_hierarchy_2<T,Data>::
|
|||
oriented_end(T va, T vb, T& vc) const
|
||||
{
|
||||
H_context_iterator ctxt, past;
|
||||
assert(get_contexts(va,vb, ctxt, past) );
|
||||
CGAL_triangulation_assertion(get_contexts(va,vb, ctxt, past) );
|
||||
if(*(ctxt->pos) == va)
|
||||
vc = ctxt->enclosing->back();
|
||||
else
|
||||
|
|
|
|||
|
|
@ -278,7 +278,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
template < class R, class W = typename R::FT>
|
||||
template < class R, class W = CGAL_TYPENAME_MSVC_NULL R::RT>
|
||||
class Regular_triangulation_euclidean_traits_2
|
||||
: public Triangulation_euclidean_traits_2<R>
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue