[vtkusers] positioning a cylinder

Amy Squillacote amy.squillacote at kitware.com
Fri Mar 30 15:19:01 EDT 2007


Hi Mark,

You can create a vtkLineSource that goes between the two lines: 
http://www.vtk.org/doc/release/5.0/html/a01687.html. Then you can pass 
the output of the line source through the vtkTubeFilter: 
http://www.vtk.org/doc/release/5.0/html/a02133.html. Turn capping on in 
the tube filter to close off the ends of the cylinder.

- Amy

Mark Wyszomierski wrote:
> Hi,
>
> I have two points in VTK space, is there an easy way to construct a
> cylinder so that its two endpoints touch the two points? Something
> like:
>
> cylinder->SetEndpoint1(x,y,z);
> cylinder->SetEndpoint2(x,y,z);
>
> Thanks,
> Mark
> _______________________________________________
> This is the private VTK discussion list. Please keep messages 
> on-topic. Check the FAQ at: http://www.vtk.org/Wiki/VTK_FAQ
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>

-- 
Amy Squillacote
Kitware, Inc.
28 Corporate Drive
Clifton Park, NY 12065
Phone: (518) 371-3971 x106




More information about the vtkusers mailing list