Cut Plane with Multiple Sources

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Cut Plane with Multiple Sources

Francesco
This post has NOT been accepted by the mailing list yet.
Hello I'will try to create a simple application with a Cut Plane that slice across various surface or mesh and tubes...
but how I do?

Sources can be assemble into one?


For example I've a list o 3d points in p

fig = figure(bgcolor=(0, 0, 0))
clipper = tvtk.ClipPolyData()
for i in range(len(p) - 1):
    line = tvtk.LineSource(point1=(p[i][0], p[i][1], p[i][2]), point2=(p[i + 1][0], p[i + 1][1], p[i + 1][2]))
    clipper.add_input(line.get_output())
    lineMapper = tvtk.PolyDataMapper(input=line.output)
    lineActor = tvtk.Actor(mapper=lineMapper)
    fig.scene.add_actor(lineActor)

Can I slice across the LineSource that I create in this code?

Thanks a Lot.