mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
Using a remove and insert method to move points to avoid problems with the CGAL
move function. If move can't be fixed by the CGAL guys then go to a complete removal and reinsertion at each step.
This commit is contained in:
@ -429,7 +429,7 @@ void Foam::CV2D::newPoints(const scalar relaxation)
|
||||
|
||||
if (surfDist < 0.2)
|
||||
{
|
||||
sizes[vit->index()] *= (1 - 0.3)*surfDist/0.2 + 0.3;
|
||||
sizes[vit->index()] *= (1 - 0.1)*surfDist/0.2 + 0.1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -138,11 +138,19 @@ inline Foam::point Foam::CV2D::toPoint3D(const Point& P) const
|
||||
|
||||
inline void Foam::CV2D::movePoint(const Vertex_handle& vh, const Point& P)
|
||||
{
|
||||
label i = vh->index();
|
||||
int i = vh->index();
|
||||
int t = vh->type();
|
||||
|
||||
move(vh, P);
|
||||
remove(vh);
|
||||
|
||||
vh->index() = i;
|
||||
Vertex_handle newVh = insert(P);
|
||||
|
||||
newVh->index() = i;
|
||||
newVh->type() = t;
|
||||
|
||||
// label i = vh->index();
|
||||
// move(vh, P);
|
||||
// vh->index() = i;
|
||||
|
||||
// vh->set_point(toPoint(p));
|
||||
// fast_restore_Delaunay(vh);
|
||||
|
||||
@ -46,7 +46,7 @@ namespace CGAL
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
template<class Gt, class Vb=CGAL::Triangulation_vertex_base_2<Gt> >
|
||||
class indexedVertex
|
||||
class indexedVertex
|
||||
:
|
||||
public Vb
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user