<div dir="ltr">So what it is doing is passing the locally 2D primitives through, which is not what you want it to do. If this was a volumetric mesh it would give you the skin. You want something like vtkSelectEnclosedPoints. <div><br></div><div>Unfortunately vtkSelectEnclosedPoints requires a surface to clip by, and that surface is exactly what you are trying to get. There might be something in VTK for this, but my quick searches haven't found it.</div><div><br></div><div>sorry</div><div><br><div><br></div><div><br></div></div><div class="gmail_extra"><br clear="all"><div><div>David E DeMarle<br>Kitware, Inc.<br>R&D Engineer<br>21 Corporate Drive<br>Clifton Park, NY 12065-8662<br>Phone: <a href="tel:518-881-4909" value="+15188814909" target="_blank">518-881-4909</a></div></div>
<br><div class="gmail_quote">On Tue, Jul 14, 2015 at 8:39 AM, Kilgus, Thomas <span dir="ltr"><<a href="mailto:t.kilgus@dkfz-heidelberg.de" target="_blank">t.kilgus@dkfz-heidelberg.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div lang="DE" link="blue" vlink="purple"><div><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">No no, my data is 3D. The screenshot just contains cross sections to illustrate how the data looks “inside”.<u></u><u></u></span></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"><u></u> <u></u></span></p><p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">Von:</span></b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> David E DeMarle [mailto:<a href="mailto:dave.demarle@kitware.com" target="_blank">dave.demarle@kitware.com</a>] <br><b>Gesendet:</b> Dienstag, 14. Juli 2015 14:35</span></p><div><div><br><b>An:</b> Kilgus, Thomas<br><b>Cc:</b> <a href="mailto:vtkusers@vtk.org" target="_blank">vtkusers@vtk.org</a><br><b>Betreff:</b> Re: [vtkusers] Filter to remove internal structure of a poly data?<u></u><u></u></div></div><p></p><div><div><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal">Ah, I thought your data was 3D, not 2D. The DSSF won't help in this case.<u></u><u></u></p><div><p class="MsoNormal"><u></u> <u></u></p></div></div><div><p class="MsoNormal"><br clear="all"><u></u><u></u></p><div><div><p class="MsoNormal">David E DeMarle<br>Kitware, Inc.<br>R&D Engineer<br>21 Corporate Drive<br>Clifton Park, NY 12065-8662<br>Phone: <a href="tel:518-881-4909" value="+15188814909" target="_blank">518-881-4909</a><u></u><u></u></p></div></div><p class="MsoNormal"><u></u> <u></u></p><div><p class="MsoNormal">On Tue, Jul 14, 2015 at 8:26 AM, Kilgus, Thomas <<a href="mailto:t.kilgus@dkfz-heidelberg.de" target="_blank">t.kilgus@dkfz-heidelberg.de</a>> wrote:<u></u><u></u></p><blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-right:0cm"><div><div><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Hi David,</span><u></u><u></u></p><p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">sounds great, but it doesn’t do anything on my data. Do you know how the filter works? Attached is my code and a screenshot how my data looks like. Any ideas? </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Regards,</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Thomas</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Code:</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> std::string inputFilename = “path/to/file”;</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> std::string outputFilename = “path/to/save”;</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> vtkSmartPointer<vtkXMLPolyDataReader> reader =</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> vtkSmartPointer<vtkXMLPolyDataReader>::New();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> reader->SetFileName ( inputFilename.c_str() );</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> reader->Update();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> vtkSmartPointer<vtkDataSetSurfaceFilter> filter = vtkSmartPointer<vtkDataSetSurfaceFilter>::New();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> filter->SetInputConnection(reader->GetOutputPort());</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> filter->Update();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> vtkSmartPointer<vtkXMLPolyDataWriter> writer = vtkSmartPointer<vtkXMLPolyDataWriter>::New();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> writer->SetInputConnection(filter->GetOutputPort());</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> writer->SetFileName(outputFilename.c_str());</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> writer->Update();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> writer->Write();</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US" style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> </span><u></u><u></u></p><p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">Von:</span></b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> David E DeMarle [mailto:<a href="mailto:dave.demarle@kitware.com" target="_blank">dave.demarle@kitware.com</a>] <br><b>Gesendet:</b> Dienstag, 14. Juli 2015 13:37<br><b>An:</b> Kilgus, Thomas<br><b>Cc:</b> <a href="mailto:vtkusers@vtk.org" target="_blank">vtkusers@vtk.org</a><br><b>Betreff:</b> Re: [vtkusers] Filter to remove internal structure of a poly data?</span><u></u><u></u></p><div><div><p class="MsoNormal"> <u></u><u></u></p><div><p class="MsoNormal">Try vtkDataSetSurfaceFilter. It produces the external skin of any dataset in the form of a polydata.<u></u><u></u></p><div><p class="MsoNormal"> <u></u><u></u></p></div></div><div><p class="MsoNormal"><br clear="all"><u></u><u></u></p><div><div><p class="MsoNormal">David E DeMarle<br>Kitware, Inc.<br>R&D Engineer<br>21 Corporate Drive<br>Clifton Park, NY 12065-8662<br>Phone: <a href="tel:518-881-4909" target="_blank">518-881-4909</a><u></u><u></u></p></div></div><p class="MsoNormal"> <u></u><u></u></p><div><p class="MsoNormal">On Tue, Jul 14, 2015 at 5:00 AM, Kilgus, Thomas <<a href="mailto:t.kilgus@dkfz-heidelberg.de" target="_blank">t.kilgus@dkfz-heidelberg.de</a>> wrote:<u></u><u></u></p><blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0cm 0cm 0cm 6.0pt;margin-left:4.8pt;margin-top:5.0pt;margin-right:0cm;margin-bottom:5.0pt"><div><div><div><div><p class="MsoNormal"><span lang="EN-US">Hi everyone,</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">I am not sure how to call this, but I was wondering if there is any filter (or combination) to remove internal structures of a PolyData? By internal I mean stuff that is not visible to the camera, unless you make the surface translucent. I know that there is a vtkPolyDataConnectivityFilter which works for some uses cases, but my data is connected at some parts. I am not even sure if this is possible, but the virtual camera could rotate around the object and every cell which is not seen (hit by a ray) could be deleted. Is there anything like this in VTK?</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">Regards,</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">Thomas</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US"> </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">Thomas Kilgus</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">German Cancer Research Center (DKFZ)</span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">Div. Medical and Biological Informatics </span><u></u><u></u></p><p class="MsoNormal"><span lang="EN-US">Junior group: Computer-assisted Interventions (E131)</span><u></u><u></u></p><p class="MsoNormal">Im Neuenheimer Feld 280<u></u><u></u></p><p class="MsoNormal">69120 Heidelberg, Germany<u></u><u></u></p><p class="MsoNormal">Phone: <a href="tel:%2B49%280%29%206221-42-3545" target="_blank">+49(0) 6221-42-3545</a><u></u><u></u></p><p class="MsoNormal"> <u></u><u></u></p></div></div></div></div><p class="MsoNormal" style="margin-bottom:12.0pt"><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>Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" target="_blank">http://markmail.org/search/?q=vtkusers</a><br><br>Follow this link to subscribe/unsubscribe:<br><a href="http://public.kitware.com/mailman/listinfo/vtkusers" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><u></u><u></u></p></blockquote></div><p class="MsoNormal"> <u></u><u></u></p></div></div></div></div></div></blockquote></div><p class="MsoNormal"><u></u> <u></u></p></div></div></div></div></div></blockquote></div><br></div></div>