FoundationPartsOperationsSurfaceLoft

SurfaceLoft

A SurfaceLoft is identical to Loft in its inputs but produces a thin shell (surface) instead of a closed solid. Use it as an intermediate step when you want to thicken, stitch, or trim a surface before turning it into a solid.

The example below pairs SurfaceLoft with Thicken to give the loft a uniform wall thickness:

from cadbuildr.foundation import *


class SurfaceLoftThickened(Part):
    def __init__(self):
        pf = PlaneFactory()
        p0 = self.xy()
        p1 = pf.get_parallel_plane(p0, 40)
        s0 = Sketch(p0)
        s1 = Sketch(p1)
        c0 = Ellipse(s0.origin, 30, 15)
        c1 = Ellipse(s1.origin, 15, 30)
        surface = SurfaceLoft(shapes=[c0, c1])
        self.add_operation(Thicken(surface=surface, thickness=2.0, both_sides=True))


show(SurfaceLoftThickened())