mirror of https://github.com/CGAL/cgal
Filtering out the insertion of repeated weighted points, allowing
is_valid to return true...
This commit is contained in:
parent
cac2d4b037
commit
90028cb645
|
|
@ -1068,16 +1068,24 @@ insert(const Weighted_point &p, Locate_type lt, Face_handle loc, int li)
|
|||
}
|
||||
|
||||
Vertex_handle vv = loc->vertex(li);
|
||||
if (power_test (vv->point(), p) < 0) {
|
||||
return hide_new_vertex (loc, p);
|
||||
}
|
||||
|
||||
v = this->_tds.create_vertex();
|
||||
v->set_point(p);
|
||||
exchange_incidences(v,vv);
|
||||
hide_vertex(loc, vv);
|
||||
regularize (v);
|
||||
return v;
|
||||
CGAL::Oriented_side side = power_test (vv->point(), p);
|
||||
|
||||
switch(side) {
|
||||
|
||||
case ON_NEGATIVE_SIDE:
|
||||
return hide_new_vertex (loc, p);
|
||||
|
||||
case ON_POSITIVE_SIDE:
|
||||
v = this->_tds.create_vertex();
|
||||
v->set_point(p);
|
||||
exchange_incidences(v,vv);
|
||||
hide_vertex(loc, vv);
|
||||
regularize (v);
|
||||
return v;
|
||||
|
||||
case ON_ORIENTED_BOUNDARY:
|
||||
return vv;
|
||||
}
|
||||
}
|
||||
case Base::EDGE:
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in New Issue