[vtkusers] Dilation of a vtkPolyData

Jeff Lee jeff at cdnorthamerica.com
Mon Apr 27 08:48:36 EDT 2009


On Sun, Apr 26, 2009 at 5:13 PM, <David.Pont at scionresearch.com> wrote:

> David Doria <daviddoria at gmail.com> wrote on 26/04/2009 23:54:03:
>
> > On Sun, Apr 26, 2009 at 6:16 AM, Maxime Taquet <hystomagna at gmail.com>
> wrote:
> > Dear all,
> >
> > I have a vtkPolyData object which represents the surface of a bone.
> > I would like to enlarge this surface of 1mm in all directions. This
> > can be seen as the new surface of a dilated version of the bone.
> >
> > Do you know any easy way to compute it?
>
> Having just replied to another post where vtkImplicitModeller was
> mentioned.... it might be worth a look for your problem,
>
>   regards, Dave
>
 you could also have a look at vtkWarpScalar to warp the bone normal to the
surface given an array of displacements (in your case a constant .01).
vtkWarpVector if you want to specify your own directions.
-Jeff

>
>
> >
> > Best,
> >
> > Maxime
> > _______________________________________________
> >
> > Maybe you could just scale the polydata using
> > #include <vtkTransformPolyDataFilter.h>
> >
> > vtkSmartPointer<vtkTransformPolyDataFilter> TransFilter =
> > vtkSmartPointer<vtkTransformPolyDataFilter>::New();
> >     TransFilter->SetInput(YourPolydata);
> >     TransFilter->SetTransform(ScaleTransform); //use vtkTransform
> > (or maybe vtkLinearTransform)
> >     TransFilter->Update();
> >     vtkPolyData* ScaledPolydata = TransFilter->GetOutput();
> >
> >
> > I think you'd have to center the data, scale it, and then move it
> > back to the original location. You'd have to figure out what % to
> > scale to achieve the 1mm goal.
> >
> > Dave_______________________________________________
> > Powered by www.kitware.com
> >
> > Visit other Kitware open-source projects at http://www.kitware.
> > com/opensource/opensource.html
> >
> > Please keep messages on-topic and check the VTK FAQ at: http://www.
> > vtk.org/Wiki/VTK_FAQ
> >
> > Follow this link to subscribe/unsubscribe:
> > http://www.vtk.org/mailman/listinfo/vtkusers
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20090427/44a4c0e6/attachment.htm>


More information about the vtkusers mailing list