[vtkusers] iterating through vtkImageStencilData
Prathamesh Kulkarni
prathameshmkulkarni at gmail.com
Wed Jul 21 10:31:08 EDT 2010
Hi David,
Thanks for the direction. The documentation does not make it very clear to
me. Could you please point/cook me a little example for accessing pixel
values of vtkImageStencilData using the method you suggested? If I am able
to do it, I'll post it out.
Prathamesh
On Tue, Jul 20, 2010 at 6:34 PM, David Gobbi <david.gobbi at gmail.com> wrote:
> Hi Prathamesh,
>
> You can use the following method of vtkImageStencilData to do the
> iteration:
>
> int vtkImageStencilData::GetNextExtent(int &r1, int &r2, int xMin,
> int xMax, int yIdx, int zIdx, int &iter);
>
> The documentation describes what each of the parameters is for. I
> started work on a proper iterator for vtkImageStencilData many, many
> years ago but never found time to finish it.
>
> David
>
>
> On Tue, Jul 20, 2010 at 5:00 PM, Prathamesh Kulkarni
> <prathameshmkulkarni at gmail.com> wrote:
> > Hello all,
> >
> > I want to be able to write vtkImageStencilData to text files in a CSV
> format
> > in order to be analyzed in some other software.
> >
> > I could not find a way to iterate through vtkImageStencilData similar to
> > vtkImageData.
> >
> > One idea is to convert the vtkImageStencilData to vtkImageData and then
> use
> > vtkImageIterator. However, I do not know how to perform this conversion.
> >
> > Has anyone tried this before? How?
> >
> > Thanks,
> > Prathamesh
> >
> > _______________________________________________
> > 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/20100721/1615458b/attachment.htm>
More information about the vtkusers
mailing list