<div>Thank you both.</div>
<div>I'll try out your suggestions.</div>
<div>By far, i tried the following pipeline:</div>
<div>1) UnstructuredGrid</div>
<div>2) vtkShrinkFilter (so i can see the hexahedrons)</div>
<div><font size="3"><font size="2">3) vtkDataSetSurfaceFilter (!)</font></font></div>
<div><font size="3"><font size="2">4) vtkSmoothPolyDataFilter</font></font></div>
<div> </div>
<div>I get what i want. I'm not really sure if ALL hexahedrons are smoothed (and not only the outer ones).</div>
<div>What do you think?</div>
<div> </div>
<div>Thanks,</div>
<div>Bill</div>
<div><font size="3"><font size="2"><font size="3"></font></font></font> </div>
<div><font size="3"><font size="2"><font size="3"> </font></font></font></div>
<div><br><br></div>
<div class="gmail_quote">2009/12/11 David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>></span><br>
<blockquote style="BORDER-LEFT: #ccc 1px solid; MARGIN: 0px 0px 0px 0.8ex; PADDING-LEFT: 1ex" class="gmail_quote">Hmm... if GeometryFilter keeps all the points, then it's possible that<br>you could generate a new vtkDataSet that combines the points from the<br>
smoothed polydata with the cells of your grid. Something like this:<br><br>smoothFilter->Update();<br>gridProducer->Update();<br>vtkDataSet *newdata = vtkDataSet::New();<br>newdata->DeepCopy(gridProducer->GetOutput());<br>
newdata->SetPoints(smoothFilter->GetOutput()->GetPoints());<br><br>Note that code like this can crash if the assumptions aren't correct.<br>Also, only the outer layer of points will be smoothed, so the<br>resulting data object might contain invalid cells. But still, this<br>
should give you ideas about how to find a proper solution.<br><font color="#888888"><br> David<br></font>
<div>
<div></div>
<div class="h5"><br><br>On Fri, Dec 11, 2009 at 8:40 AM, Bill Chivas <<a href="mailto:noo134@googlemail.com">noo134@googlemail.com</a>> wrote:<br>> vtkGeometryFilter works fine. I wonder if i could get back to<br>
> unstructuredGrid and hexahedrons by using the points.<br>> I noticed that the number of points are the same in unstructuredGrid and<br>> vtkGeometryFilter (vtkPolyData).<br>> Could i "reproduce" the original hexahedron topology?<br>
><br>> Thanks,<br>> Bill<br>><br>> 2009/12/11 David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>><br>>><br>>> On Fri, Dec 11, 2009 at 7:11 AM, Bill Chivas <<a href="mailto:noo134@googlemail.com">noo134@googlemail.com</a>><br>
>> wrote:<br>>> > Hello all,<br>>> ><br>>> > I would like to use vtkSmoothPolyDataFilter on an unstructuredGrid, but<br>>> > i<br>>> > read the particular filter applies only to vtkPolyData.<br>
>> > My unstructuredGrid consists of hexahedrons.<br>>> > How could i use the filter?<br>>> > One idea i thought is to extract the surface iterately and apply to<br>>> > these<br>>> > surfaces, but i don't know if it's ok.<br>
>><br>>> I've seen some people create a "skin" polydata with vtkGeometryFilter,<br>>> apply the smoothing to the "skin" and then use a custom filter to<br>>> propagate the smoothing throughout the interior of their mesh. The<br>
>> vtkGeometryFilter is a basic anything-to-polydata filter, so it is<br>>> easy to use. The final step of using the smoothed polydata to create<br>>> a smoothed mesh is nontrivial, though.<br>>><br>
>> David<br>><br>><br></div></div></blockquote></div><br>