Hallo,
Ich nutze einen BSpline2D zur exakten Abbildung einer Kurve. Der erstellte Spline ist valid. Ich bekomme ihn aber nicht als ModelElement2D nach Allplan.
Den gleichen Spline mit ConvertTo3D zu einem BSpline3D konvertiert und als ModelElement3D funktioniert einwandfrei.
Anbei die Konsolenausgabe und der code zum Erstellen des Splines.
IsPeriodic(0)
Degree(2)
PointCount(3)
WeightCount(3)
Weights(1, 1, 1)
KnotCount(6)
Knots(0, 0, 0, 1, 1, 1)
Points(
(389361.338586517, 646455.2527631306)
(639361.338586517, 791671.7897024201)
(889361.338586517, 759664.6636304968)))
BSpline3D BSpline3D(
IsPeriodic(0)
Degree(2)
PointCount(3)
WeightCount(3)
Weights(1, 1, 1)
KnotCount(6)
Knots(0, 0, 0, 1, 1, 1)
Points(
(389361.338586517, 646455.2527631306, 0)
(639361.338586517, 791671.7897024201, 0)
(889361.338586517, 759664.6636304968, 0)))
points=AllplanGeo.Point2DList([
AllplanGeo.Point2D(389361.338586517,646455.2527631306),
AllplanGeo.Point2D(639361.338586517,791671.7897024201),
AllplanGeo.Point2D(889361.338586517,759664.6636304968)])
weights=AllplanUtil.VecDoubleList([1.0,1.0,1.0])
knots=AllplanUtil.VecDoubleList([0.0,0.0,0.0,1.0,1.0,1.0])
bspline2d=AllplanGeo.BSpline2D(points,weights,knots,2,False)
_,bspline3D=AllplanGeo.ConvertTo3D(geo)2D und 3D sind gleich und beide haben .IsValid() = True . 3D wird angezeigt, 2D nicht. Natürlich achte ich darauf, das 2D Element auch als ModelElement2D zu übergeben.
Woran liegts?
Beste Grüße