Hi everybody,<br>
<br>
I have create a class in which I have to set (and get) a parameter, the
brightness threshold. For that,&nbsp; I used itk set/get macro:<br>
<br>
&nbsp; itkSetMacro(BrightnessThreshold, int);<br>
&nbsp; itkGetConstReferenceMacro(BrightnessThreshold, int);<br>
<br>
But the program doesn't want to compile. The errors given are:<br>
<br>
/home/gally/susan/itkUsanWeightFunction.h: In method `void<br>
itk::UsanWeightFunction&lt;TOperator&gt;::SetBrightnessThreshold (int) [with TOperator = FloatType]':<br>
/home/gally/susan/itkFSLSusanImageFilter.txx:159:&nbsp;&nbsp;
instantiated from `itk::FSLSusanImageFilter&lt;TInputImage,
TOutputImage&gt;::ThreadedGenerateData (typename
TOutputImage::RegionType &amp;, int) [with TInputImage = main (int,
char **)::InputImageType, TOutputImage = main (int, char
**)::OutputImageType]'<br>
/home/gally/programmes/itk/InsightToolkit-1.8.1/Code/IO/itkImageFileWriter.txx:158:&nbsp;&nbsp; instantiated from here<br>
/home/gally/susan/itkUsanWeightFunction.h:93: no matching function for call to<br>
`itk::UsanWeightFunction&lt;FloatType&gt;::GetDebug ()'<br>
/home/gally/susan/itkFSLSusanImageFilter.txx:159:&nbsp;&nbsp;
instantiated from `itk::FSLSusanImageFilter&lt;TInputImage,
TOutputImage&gt;::ThreadedGenerateData (typename
TOutputImage::RegionType &amp;, int) [with TInputImage = main (int,
char **)::InputImageType, TOutputImage = main (int, char
**)::OutputImageType]'<br>
/home/gally/programmes/itk/InsightToolkit-1.8.1/Code/IO/itkImageFileWriter.txx:158:&nbsp;&nbsp; instantiated from here<br>
/home/gally/susan/itkUsanWeightFunction.h:93: no matching function for call to<br>
`itk::UsanWeightFunction&lt;FloatType&gt;::Modified ()'<br>
/home/gally/susan/itkUsanWeightFunction.h: In method `const int<br>
&amp;itk::UsanWeightFunction&lt;TOperator&gt;::GetBrightnessThreshold () const [with TOperator = FloatType]':<br>
/home/gally/programmes/itk/InsightToolkit-1.8.1/Code/Common/itkPoint.h:97:&nbsp;&nbsp; instantiated from here<br>
/home/gally/susan/itkUsanWeightFunction.h:94: no matching function for call to<br>
`itk::UsanWeightFunction&lt;FloatType&gt;::GetDebug () const'<br>
/home/gally/susan/itkUsanWeightFunction.h:94: passing `const itk::UsanWeightFunction&lt;FloatType&gt;' as<br>
`this' argument of `const char *itk::UsanWeightFunction&lt;TOperator&gt;::GetNameOfClass () [with TOperator =<br>
FloatType]' discards qualifiers<br>
<br>
I understand that I need GetDebug() and Modified() method, but I don't
know why... Does my class needs inheritance of something??<br>
<br>
Thanks for advices,<br>
<br>
Regards,<br>
<br>
Franz<br>