[Insight-users] boundary condition and neighborhood iterator

Yann GAVET yann.gavet at univ-st-etienne.fr
Wed, 28 Apr 2004 11:10:12 +0200


This is a multi-part message in MIME format.
--------------020006070904020100040904
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Hi all,

I want to specify a ConstantBoundaryCondition in a shaped iterator; my 
code looks like:

// appropriate headers

// types definitions
1  typedef unsigned char PixelType;
2  typedef itk::Image< PixelType, 2 >  ImageType;

3  typedef itk::ConstantBoundaryCondition< ImageType > 
MyBoundaryConditionType;
4  typedef itk::ConstShapedNeighborhoodIterator< ImageType ,
                                                MyBoundaryConditionType 
 > ShapedNeighborhoodIteratorType;

...
5  ShapedNeighborhoodIteratorType it=...;
6  const MyBoundaryConditionType *condition = NULL;
...
7 condition = it.GetBoundaryCondition();

===========
At this last line (7), the compiler outputs an error, and I dont know 
how to correct it, because I thought I had templated the 
neighborIteratorType with MyBoundaryCondition.

OuvertureDiagonale.cc: In function `int main(int, char**)':
OuvertureDiagonale.cc:213: error: cannot convert `const 
itk::ZeroFluxNeumannBoundaryCondition<main(int, char**)::ImageType>*' to 
`const main(int, char**)::MyBoundaryConditionType*' in assignment

Can anyone explain my problem?

thank you for your time.
Yann

--------------020006070904020100040904
Content-Type: text/x-vcard; charset=utf8;
 name="yann.gavet.vcf"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
 filename="yann.gavet.vcf"

begin:vcard
fn:Yann Gavet
n:Gavet;Yann
org;quoted-printable:CHU Saint-Etienne;EA 3063 - Survie et adh=C3=A9rence cellulaire dans les cancers et les gre=
	ffes
adr;quoted-printable:;;15 rue A. Par=C3=A9;;;42000;France
email;internet:yann.gavet at univ-st-etienne.fr
title;quoted-printable:Ing=C3=A9nieur Civil des Mines
version:2.1
end:vcard


--------------020006070904020100040904--