<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2900.2722" name=GENERATOR></HEAD>
<BODY>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff size=2>Franz,
</FONT></SPAN></DIV>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff size=2>I
added a NeighborhoodOperator subclass a while back that you may want to look
at. It is probably as stripped down as possible. Take a look at
Insight/Code/Common/itkAnnulusOperator.h. This operator only provides the
GenerateCoefficients() and Fill() methods. I </FONT></SPAN></DIV>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff size=2>use
the operator to apply to all the pixels under the neighborhood (i.e. it is not
directional).</FONT></SPAN></DIV>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=373080114-06092005><FONT face=Arial color=#0000ff
size=2>Jim</FONT></SPAN></DIV>
<BLOCKQUOTE>
<DIV class=OutlookMessageHeader dir=ltr align=left><FONT face=Tahoma
size=2>-----Original Message-----<BR><B>From:</B>
insight-users-bounces+millerjv=crd.ge.com@itk.org
[mailto:insight-users-bounces+millerjv=crd.ge.com@itk.org]<B>On Behalf Of
</B>l franz<BR><B>Sent:</B> Tuesday, September 06, 2005 7:36 AM<BR><B>To:</B>
insight-users@itk.org<BR><B>Subject:</B> [Insight-users] Neighborhood
Operator<BR><BR></FONT></DIV>Hi everybody,<BR><BR>I'm creating my
non-directional neighborhood operator. For that, I have created a
"GenerateCoefficients" method and a "Fill" method. Then, to generate the
coefficients of this operator, I call "CreateToRadius ( SizeType &)"
inherted from the "NeighborhoodOperator" class. The input parameter of this
last method is the operator's raduis.<BR><BR>This operator will be used with
"NeighborhoodInnerProduct" class.<BR><BR>The operator size is equal to the
neighborhood size. So they have the same radius. I have defined the
neighborhoodradius like this:<BR><BR> typedef Neighborhood<
InputPixelType, ImageDimension > NeighborhoodType;<BR> typename
NeighborhoodType::SizeType neighborhoodRadius;<BR><BR>Then, I called the
"CreateToRadius" method like this:<BR><BR>
myOperator.CreateToRadius ( neighborhoodRadius );<BR><BR>But that doesn't
work. Here is the error given by the compiler: <BR><BR>no matching function
for call to<BR>`itk::UsanOperator<main (int, char **)::InputImageType, 2,
itk::NeighborhoodAllocator<PixelType><BR>>::CreateToRadius
(itk::Size<3> &)'<BR><BR>candidates<BR>are: void
itk::NeighborhoodOperator<TPixel, VDimension,
TAllocator>::CreateToRadius (typename<BR>itk::Neighborhood<TPixel,
VDimension, TAllocator>::SizeType &) [with TPixel = PixelType, unsigned
int<BR>VDimension = 2, TAllocator =
itk::NeighborhoodAllocator<PixelType>]<BR><BR>So, if I understand well,
the radius type is wrong. The radius type must be itk::Neighborhood<TPixel,
VDimension, TAllocator>::SizeType . But, for me, it's already the case...
So I don't really see the reason of this problem.<BR><BR>Does someone has an
advice on it?<BR><BR>Thanks a
lot,<BR><BR>Regards,<BR><BR>Franz<BR><BR></BLOCKQUOTE></BODY></HTML>