[Insight-developers] itkVTKPolyDataReader.h reads ascii only--- why?

Luis Ibanez luis.ibanez at kitware.com
Wed Oct 20 17:37:35 EDT 2010


Vince, Brian

An alternative methods is illustrated in:

ITKApps/Auxiliary/vtk/ExtractIsoSurface.cxx

(...surface normals, if present, should
probably be reoriented too...)


     Luis


---------------------------------------------------
On Wed, Oct 20, 2010 at 9:51 AM, Vincent Magnotta <
vincent-magnotta at uiowa.edu> wrote:

> Brian,
>
> I have taken the same approach as Slicer with this effort. Essentially a
> VTK
> transform is generated from the direction cosines, spacing and origin. The
> VTK image is then set to have an origin of 0,0,0 and spacing of 1,1,1. Once
> the mesh is generated, the resulting poly data is transformed using the VTK
> transform. The resulting pipeline is then
>
> ITK-Image =>  VTK-Image => Change VTK Info => MarchingCube => VTK-Mesh
> => Transform VTK-Mesh => ITK-Mesh
>
>
> Vince
>
>
> On 10/19/10 10:40 PM, "brian avants" <stnava at gmail.com> wrote:
>
> > Vince --- My understanding (though perhaps outdated?) is that vtk
> > meshes lose direction information (obtained by calling GetDirection on
> > an itk image) b/c a vtk image does not store this information.  So, if
> > you create a pipeline like this:
> >
> > ITK-Image =>  VTK-Image => MarchingCube => VTK-Mesh => ITK-Mesh
> >
> > then you will lose the directionality information at the ITK to VTK
> > stage.  Which is a problem if the direction is not the identity. The
> > mesh, consequently, doesnt have orientation either, unless you
> > explicitly set it yourself (not hard to do) by mapping the vtk-points
> > through the orienting transformation.  So, maybe there is a filter
> > that already does this or perhaps the vtk image object is updated and
> > now stores the orientation?   Or maybe there's another vtk filter that
> > should be inserted into the pipeline above to reorient the output of
> > marching cubes back into ITK physical space?
> >
> > B
> >
> >
> > On Tue, Oct 19, 2010 at 10:55 PM, Magnotta, Vincent A
> > <vincent-magnotta at uiowa.edu> wrote:
> >> Brian,
> >>
> >> I don't understand this question. Isn't the VTK point information
> already in
> >> physical space? Maybe this is just how I have always dealt with the VTK
> >> data. I believe that Slicer also follows this convention.
> >>
> >> Vince
> >>
> >>
> >> ----------------------
> >> Associate Professor
> >> Department of Radiology
> >> 0453-D JCP
> >> 200 Hawkins Drive
> >> Iowa City, IA 52242
> >> E-mail: vincent-magnotta at uiowa.edu
> >> Phone: 319-356-8255 Fax: 319-353-6275
> >> Website: http://www.radiology.uiowa.edu
> >>
> >>
> >>
> >> -----Original Message-----
> >> From: insight-developers-bounces at itk.org on behalf of brian avants
> >> Sent: Tue 10/19/2010 2:57 PM
> >> To: Alexandre GOUAILLARD
> >> Cc: Insight-developers at itk.org; Luis Ibanez
> >> Subject: Re: [Insight-developers] itkVTKPolyDataReader.h reads ascii
> only---
> >> why?
> >>
> >> Hi Alexandre, Wanlin , dev-list
> >>
> >> Would it be possible to add a reference image space to the vtk reader?
> >>  That is, because vtk files dont have physical space associated with
> >> them, we could have an optional input to the filter that would
> >> reorient the mesh using the space of the image from which the mesh was
> >> originally derived.  I guess this should probably be a separate
> >> unoriented to oriented mesh filter ... have you already resolved this
> >> issue?
> >>
> >> Brian
> >> _______________________________________________
> >> Powered by www.kitware.com
> >>
> >> Visit other Kitware open-source projects at
> >> http://www.kitware.com/opensource/opensource.html
> >>
> >> Kitware offers ITK Training Courses, for more information visit:
> >> http://kitware.com/products/protraining.html
> >>
> >> Please keep messages on-topic and check the ITK FAQ at:
> >> http://www.itk.org/Wiki/ITK_FAQ
> >>
> >> Follow this link to subscribe/unsubscribe:
> >> http://www.itk.org/mailman/listinfo/insight-developers
> >>
> >>
> >
> >
>
> ----------------------
> Associate Professor
> Department of Radiology
> 0453-D JCP
> 200 Hawkins Drive
> Iowa City, IA 52242
> E-mail: vincent-magnotta at uiowa.edu
> Phone: 319-356-8255 Fax: 319-353-6275
> Website: http://www.radiology.uiowa.edu
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/mailman/private/insight-developers/attachments/20101020/db9f410d/attachment.htm>


More information about the Insight-developers mailing list