[Python] Loft splines cadquery [closed]

Discussão em 'Python' iniciado por Stack, Março 21, 2025.

  1. Stack

    Stack Membro Participativo

    I am trying to make a LOFT on the splines that I generate to have a smooth surface but I get the following error:

    ValueError: Nothing to loft


    The part of my code that is creating a conflict is the following:

    for i in range(num_circulos):
    z = i * separacion
    coordenadas_circulo = generar_coordenadas_circulo(radio, profundidades)

    spline = cq.Workplane("XY").spline(coordenadas_circulo).close()

    spline = spline.translate((0, 0, z))

    splines.append(spline)

    todas_las_splines = cq.Workplane("XY")

    for spline in splines:
    todas_las_splines = todas_las_splines.add(spline)

    lofted_object = todas_las_splines.loft()

    show_object(lofted_object)


    With the function coordenadas_circulo, I return x,y coordinates. Yes, all splines have the same points, they create circles with a small relief:

    [1] [1]: https://i.sstatic.net/zO1Uyg15.png

    Continue reading...

Compartilhe esta Página