def curves2d_from_curves(): major, minor = 12, 4 axis = gp_OX2d() ellipse = GCE2d_MakeEllipse(axis, major, minor).Value() trimmed_curve = Geom2d_TrimmedCurve(ellipse, -1, 2, True) bspline = geom2dconvert_CurveToBSplineCurve(trimmed_curve, Convert_TgtThetaOver2) display.DisplayShape(bspline, update=True)
def test_curves2d_from_curves(self): '''Test: curves 2d from curves''' major, minor = 12, 4 axis = gp_OX2d() ell = GCE2d_MakeEllipse(axis, major, minor) E = ell.Value() TC = Geom2d_TrimmedCurve(E, -1, 2, True) SPL = geom2dconvert_CurveToBSplineCurve(TC, Convert_TgtThetaOver2)