[Insight-users] multiresolutionPyramidFilter error ...

Lagaffe lagaffe74130 at yahoo.fr
Fri Jan 27 08:03:03 EST 2006


Hello,
I try a simple program with the
itkMultiResolutionPyramidImageFilter and I have an
error:
My configuration is Mac osx 10.4, gcc 4.01 and ITK
2.4.1.

itk::ExceptionObject (0x156a290)
Location: "Unknown" 
File:
/usr/local/InsightToolkit-2-4-1/Code/Common/itkMultiThreader.cxx
Line: 358
Description: itk::ERROR: MultiThreader(0x2815800):
Exception occurred during SingleMethodExecute

my program:
typedef unsigned char PixelType;
	const unsigned int Dimension = 2;
	const unsigned int numberOfLevels = 2;
	typedef itk::Image< PixelType, Dimension >   
ImageType;
	
	
	typedef itk::ImageFileReader< ImageType > 
ReaderType;
	typedef itk::ImageFileWriter< ImageType > 
WriterType;
	ReaderType::Pointer reader = ReaderType::New();
	WriterType::Pointer writer = WriterType::New();
	
	
	
	const char * inputFilename  = "BrainT1Slice.png";
	
	reader->SetFileName( inputFilename  );
	typedef itk::MultiResolutionPyramidImageFilter<
		ImageType,
		ImageType > FixedImagePyramidType;
	
	FixedImagePyramidType::Pointer myPyramid = 
		FixedImagePyramidType::New();
	
	myPyramid->SetNumberOfLevels(numberOfLevels );
	myPyramid->SetInput(reader->GetOutput() ); 
	try {
	myPyramid->Update();
	}
	catch( itk::ExceptionObject & err ) 
    { 
		std::cerr << "ExceptionObject caught !" <<
std::endl; 
		std::cerr << err << std::endl; 
		return EXIT_FAILURE;
    } 

many thanks for help
arnaud


	

	
		
___________________________________________________________________________ 
Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs exceptionnels pour appeler la France et l'international.
Téléchargez sur http://fr.messenger.yahoo.com


More information about the Insight-users mailing list