[Insight-users] Gradient Magnitude

LaMoOsH .. xlolla28x at hotmail.com
Mon May 2 09:27:47 EDT 2011


Hi
 
Thank you for your help. 
 
No, i dont have a list of indices.
I just used the LineConstIterator to draw a line between my two points. 
now i need check the gray-level value between these two points and find the pixel with the maximun gray-level value on that line.
so i want my output to be an index.
should i make an if loop inside the while loop that checks for the highest value?
 
Thanks . 
 
 
 
> Date: Sun, 1 May 2011 19:04:45 -0400
> Subject: Re: [Insight-users] Gradient Magnitude
> From: daviddoria at gmail.com
> CC: xlolla28x at hotmail.com; insight-users at itk.org
> 
> On Sun, May 1, 2011 at 6:57 PM, Neil Panjwani <paniwani at gmail.com> wrote:
> > If you know the indexes of the line, you could use the image region iterator
> > with index to scan those indices and find the highest value using an if
> > statement.
> 
> Here is an example of what Neil suggested (you'd have to check
> "iterator.GetIndex() == AnyOfYourIndices" for every pixel visited by
> the iterator):
> http://www.vtk.org/Wiki/ITK/Examples/Iterators/ImageRegionIteratorWithIndex
> 
> If you have the end points of the line rather than the list of indices
> composing the line, you could use this:
> http://www.vtk.org/Wiki/ITK/Examples/Iterators/LineConstIterator
> 
> David
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20110502/83d47df1/attachment.htm>


More information about the Insight-users mailing list