<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>Thanks for the code this was really helpful! Just one additional question: vtkCylinders have no ending - is this correct? Is there a a way to "cut" them at a specific point? (Some of my cylinders are wider than they are long.)</div><div><br></div><div>Peter</div><br><div><div>Am 01.11.2011 um 03:03 schrieb Quang Tran:</div><br class="Apple-interchange-newline"><blockquote type="cite"><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif">Hi,</font></font></font><div><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif">You should use vtkImplicitBoolean and&nbsp;vtkClipPolyData to do this task. One of cylinder must be modeling to implicit function (you should use vtkCylinder and make any transform if necessary), set this implicit function as an input of the clipper (vtkClipPolydata), see SetClipFunction; the other cylinder is input parameter of SetInput function of clipper. After that you will have a result of this clipper as vtkPolyData. I think this result is what you need.</font></font></font></div>

<div><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif"><br></font></font></font></div><div><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif">You should use vtkCylinder rather than&nbsp;vtkCylinderSource because&nbsp;</font></font></font><span class="Apple-style-span" style="color: rgb(51, 51, 51); font-family: arial, helvetica, sans-serif; font-size: large; ">vtkCylinder is an implicit function and can use for clipping.</span></div>

<div><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif"><br></font></font></font></div><div><font color="#333333"><font size="4"><font face="arial,helvetica,sans-serif">/Quang<br></font></font></font><br>

<div class="gmail_quote">2011/10/31 Peter <span dir="ltr">&lt;<a href="mailto:peter-dpl@pre-dev.de">peter-dpl@pre-dev.de</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

Hello,<br>
<br>
i would like to calculate the intersection of two cylinders. A general solution is to use vtkImplicitBoolean and vtkExtractGeometryFilter. Unfortunately vtkImplicitBoolean can't handle vtkCylinderSource. Is there an alternative or a way to convert cylinder objects to grids (at least to approximate a cylinder)?<br>


<br>
Many thanks in advance!<br>
<br>
Peter<br>
<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com/" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote></div><br></div>
</blockquote></div><br></body></html>