<div class="gmail_quote">2011/4/21 LaMoOsH .. <span dir="ltr"><<a href="mailto:xlolla28x@hotmail.com">xlolla28x@hotmail.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div>
Hello, <br>
<br>
I am new to itk, and trying to draw a line between two points.<br>
<br><font color="#0000ff" size="2"><font color="#0000ff" size="2">
typedef</font></font><font size="2"> itk::LineConstIterator< OutputImageType > LineIteratorType;<br>
LineIteratorType it( reader, (170.910,144.438),(170.910,450.510) );<br>
it.GoToBegin();<br>
</font><font color="#0000ff" size="2"><font color="#0000ff" size="2">while</font></font><font size="2"> (!it.IsAtEnd())<br>
{<br>
std::cout << (</font><font color="#0000ff" size="2"><font color="#0000ff" size="2">float</font></font><font size="2">)it.Get() << std::endl;<br>
++it;<br>
}<br>
<br>
can I know what is wring with this code?<br>
the error is <br>
<br><font size="2">
error C2664: 'itk::LineConstIterator<TImage>::LineConstIterator(const itk::Image<TPixel,VImageDimension> *,const itk::Index<VIndexDimension> &,const itk::Index<VIndexDimension> &)' : cannot convert parameter 1 from 'itk::SmartPointer<TObjectType>' to 'const itk::Image<TPixel,VImageDimension> *'<br>
<br>
i think the way im writing the points might be wrong. not sure.<br>
my reader a reader to an image already defined before and the pixel is of type float. <br>
output image type is the output of another function that was applied on my image. <br>
<br>
hope i get some help.<br>
<br>
Thank you. <br></font></font></div></blockquote><div><br>Have you looked at this?<br><br><a href="http://www.vtk.org/Wiki/ITK/Examples/Iterators/LineIterator">http://www.vtk.org/Wiki/ITK/Examples/Iterators/LineIterator</a><br clear="all">
<br>David <br></div></div>