[Insight-users] ImageRegionIterator
Luis Ibanez
luis.ibanez at kitware.com
Thu Dec 11 16:35:42 EST 2008
Hi Javier,
You may want to try the following:
IteratorType itr( image, image->GetBufferedRegion() );
itr.GoToBegin();
while( !itr.IsAtEnd() )
{
IndexType index = itr.GetIndex();
PointType point;
image->TransformIndexToPhysicalPoint( index, point );
double x = point[0];
double y = point[1];
double z = point[2];
++itr;
}
Regards,
Luis
---------------------------------------------
Javier González González-Zabaleta wrote:
> Hi,
>
> I need to use an ImageRegionIterator (it) and when I'm over a point with
> the iterator, I want to know the value of that point (using it.Get())
> and the X, Y (and Z) values too, but I can't find the method to obtain
> that information.
>
> Thank You.
>
> Javier González
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Insight-users mailing list
> Insight-users at itk.org
> http://www.itk.org/mailman/listinfo/insight-users
More information about the Insight-users
mailing list