<div>On Tue, Jul 12, 2011 at 9:13 AM, Oldrich Svec <span dir="ltr"><<a href="mailto:oldrich.svec@gmail.com">oldrich.svec@gmail.com</a>></span> wrote:</div><div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Hi,<br>
<br>
I would like to create many cylinders with different positions and<br>
orientations and save them to the vtp file. So far I managed to create<br>
vtkCylinderSource but I have problems to rotate it and save it using<br>
vtkXMLPolyDataWriter. Could you please provide me with a short code<br>
doing that?<br>
<br>
Thank you in advance<br>
Oldrich<br></blockquote><div><br></div><div>You can apply your transform to each object with this:</div><div><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/Filters/TransformPolyData">http://www.vtk.org/Wiki/VTK/Examples/Cxx/Filters/TransformPolyData</a></div>
<div><br></div><div>then combine them together with this:</div><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/Filters/CombinePolydata">http://www.vtk.org/Wiki/VTK/Examples/Cxx/Filters/CombinePolydata</a><br clear="all">
<br></div><div class="gmail_quote">then write them with this:</div><div class="gmail_quote"><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/WriteVTP">http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/WriteVTP</a></div><div class="gmail_quote">
<br><div>Good luck,</div><div><br></div><div>David</div></div></div>