Hi,<br><br>I was wondering if you could change the InputPixelType easily ? <br>I have tried something like :<br><span><br> int test = 1; // just to be sure it enters the first if for InputPixeltype to be defined<br>
if( test == 1)<br> {<br> typedef unsigned char InputPixelType; <br> typedef unsigned char OutputPixelType; <br> }<br> else<br> {<br> typedef short InputPixelType; <br> typedef short OutputPixelType;
<br> }<br> <br>typedef itk::Image< InputPixelType, 2 > InputImageType;<br>typedef itk::Image< OutputPixelType, 2> OutputImageType;<br><br>But It doesn't work: gives that error " Error 4 error C2065: 'InputPixelType' : undeclared identifier e:\tmp\Imageimport\binarytest.cxx 62 "
<br>If i put directly one type it works, but if i put an "if", even though I am sure in goes in, the InputPixelType isn't known. Could you explain me why it doesn't recognize it ?<br><br>Thank you in advance,
<br>Regards,<br><br>Frédéric<br><br><br><br><br></span>