Skip to content
Snippets Groups Projects
Commit b966b4bb authored by Wendy Merks-Swolfs's avatar Wendy Merks-Swolfs
Browse files

It might happen that in the first round (when i is zero), d < lc * .3 and so...

It might happen that in the first round (when i is zero), d < lc * .3 and so v0 is still the begin point of the edge. If then v0->getParameter(0, t0); is called, it will always fill in t0 and return false (which is not caught here). When the edge has bounds which do not start at 0, the value of t0 is not correct. This issue is now fixed by projecting the node back on the edge if the node is on a point instead of the edge.
parent 16332562
Branches
Tags
No related merge requests found
...@@ -405,7 +405,15 @@ static void filterPoints(GEdge*ge, int nMinimumPoints) ...@@ -405,7 +405,15 @@ static void filterPoints(GEdge*ge, int nMinimumPoints)
v->getParameter(0,t); v->getParameter(0,t);
if (i != 0){ if (i != 0){
double t0; double t0;
v0->getParameter(0,t0); if (v0->onWhat()->dim() == 0)
{
// Vertex is begin point
t0 = ge->parFromPoint(SPoint3(v0->x(), v0->y(), v0->z()));
}
else
{
v0->getParameter(0, t0);
}
t=0.5*(t+t0); t=0.5*(t+t0);
} }
double lc = F_LcB(ge, t); double lc = F_LcB(ge, t);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment