You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
a segment contains guide curves, but none is located at relative circumference 0.
a segment contains a single guide curve.
This issue can be reproduced using the following test case: ColaGuideCurve.zip. Without any modifications, the test case should work (TiGL creates the expected fuselage loft). The fuselage consists of a single segment with guide curves at relative circumference 0 and 0.5. Commenting out either of the two guide curves will cause TiGL to not successfully create the loft and return the following error:
ERR 03/30 12:09:05 CTiglMakeLoft.cpp:229] Could not create loft with guide curves. Error code = 2
It seems like the error originates in src/contrib/MakeLoops.cxx.
Click for some first debugging insights.
Case 1: A segment contains guide curves, but none is located at relative circumference 0
This can be reproduced with the test case by commenting out or deleting the guide curve with uID Duct_9_upperGuideCurveSegment1. This leaves a single guide curve at relative circumference 0.5.
ERR 03/30 12:09:05 CTiglMakeLoft.cpp:229] Could not create loft with guide curves. Error code = 2
Debugging reveals that the source of the error lies in this piece of code:
// otherwise check if the edge is contained in the guides
else { //<anEdge> is in <myGuideEdges>
ForwardGuideFound = Standard_True;
}
}
}
// if the current vertex is attached to a guide and a profile edge,
// both starting at the vertex, it is considered to be the starting corner
if (ForwardSectionFound && ForwardGuideFound) {
foundStartingCorner = true;
break;
}
}
}
if (!foundStartingCorner) {
myStatus = MAKELOOPS_FAIL_STARTINGPOINT;
return;
}
TiGL searches the grid of profiles and guide curves for a starting corner, which is a vertex with minimum neighboring edges. At this vertex, TiGL finds a "ForwardSection", i.e. the fuselage profile, but no "ForwardGuide" (presumably because none is defined at relative circumference 0). As a consequence, MakeLoops returns with status MAKELOOPS_FAIL_STARTINGPOINT.
Case 2: A segment contains a single guide curve.
Case 1 is a special case of this one. This can be reproduced by commenting out either of the two guide curves Duct_9_upperGuideCurveSegment1 or Duct_9_lowerGuideCurveSegment1. Let's assume that we comment out the second guide curve and keep the guide curve Duct_9_upperGuideCurveSegment1 at relative circumference 0, as this reveals a different bug.
Debugging reveals that in the first pass of the while-loop starting in
But at this time, NextStartCorner is null, so that for the second pass of the while-loop, both StartCorner and NextCorner are null as well. At the beginning of the second pass of the while-loop
The lofting of a fuselage fails if
This issue can be reproduced using the following test case: ColaGuideCurve.zip. Without any modifications, the test case should work (TiGL creates the expected fuselage loft). The fuselage consists of a single segment with guide curves at relative circumference 0 and 0.5. Commenting out either of the two guide curves will cause TiGL to not successfully create the loft and return the following error:
It seems like the error originates in
src/contrib/MakeLoops.cxx
.Click for some first debugging insights.
Case 1: A segment contains guide curves, but none is located at relative circumference 0
This can be reproduced with the test case by commenting out or deleting the guide curve with uID
Duct_9_upperGuideCurveSegment1
. This leaves a single guide curve at relative circumference 0.5.Debugging reveals that the source of the error lies in this piece of code:
tigl/src/contrib/MakeLoops.cxx
Lines 178 to 215 in e5d4ee8
TiGL searches the grid of profiles and guide curves for a starting corner, which is a vertex with minimum neighboring edges. At this vertex, TiGL finds a "ForwardSection", i.e. the fuselage profile, but no "ForwardGuide" (presumably because none is defined at relative circumference 0). As a consequence,
MakeLoops
returns with statusMAKELOOPS_FAIL_STARTINGPOINT
.Case 2: A segment contains a single guide curve.
Case 1 is a special case of this one. This can be reproduced by commenting out either of the two guide curves
Duct_9_upperGuideCurveSegment1
orDuct_9_lowerGuideCurveSegment1
. Let's assume that we comment out the second guide curve and keep the guide curveDuct_9_upperGuideCurveSegment1
at relative circumference 0, as this reveals a different bug.Debugging reveals that in the first pass of the while-loop starting in
tigl/src/contrib/MakeLoops.cxx
Line 274 in e5d4ee8
the code will enter the true-branch of this if-clause:
tigl/src/contrib/MakeLoops.cxx
Lines 559 to 567 in e5d4ee8
But at this time,
NextStartCorner
is null, so that for the second pass of the while-loop, bothStartCorner
andNextCorner
are null as well. At the beginning of the second pass of the while-looptigl/src/contrib/MakeLoops.cxx
Lines 275 to 278 in e5d4ee8
Corner
will be null, so that we never enter the true-branch oftigl/src/contrib/MakeLoops.cxx
Lines 298 to 314 in e5d4ee8
and therefore
E1
will remain null. Finally, this causesMakeLoops
to fail here:tigl/src/contrib/MakeLoops.cxx
Lines 330 to 334 in e5d4ee8
The text was updated successfully, but these errors were encountered: