[vtkusers] Solid Voxelization with VTK

David Gobbi david.gobbi at gmail.com
Tue Sep 25 06:20:07 EDT 2018


Hi Berti,

Just a few extra comments about the three "preprocessing" steps that you
apply in your sample code:

For vtkPolyDataNormals, you might want to add
normalsFilter->AutoOrientNormalsOn(), since this option is specifically
designed to fix inside-out shapes like the Eiffel tower model.  And
normalsFilter->SplittingOff() will make this filter work faster.  It would
also be good if the comment mentioned that the purpose of the filter is to
enforce consistent orientation of the polygons, and that the filter is
optional if all the polygons are already correctly oriented.

The vtkStripper should be removed, unless you actually saw that it provides
some benefit.  The vtkPolyDataToImageStencil class should give exactly the
same results for triangles as for strips.  And vtkTriangleFilter is only
needed if the input polygons are not flat.

Thanks again for the code,
 - David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: skull2.jpg
Type: image/jpeg
Size: 64281 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0004.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: skull1.png
Type: image/png
Size: 281975 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: eiffel_tower_correct.png
Type: image/png
Size: 80360 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0003.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: alienqueen_voxelization.jpg
Type: image/jpeg
Size: 65454 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0005.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: queen_close1.jpg
Type: image/jpeg
Size: 132745 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0006.jpg>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: queen_close2.jpg
Type: image/jpeg
Size: 28658 bytes
Desc: not available
URL: <https://public.kitware.com/pipermail/vtkusers/attachments/20180925/c10dd2db/attachment-0007.jpg>


More information about the vtkusers mailing list