[Insight-users] reading dicom error
Dan Mueller
dan.muel at gmail.com
Tue Dec 28 07:17:51 EST 2010
Hi Ali,
Can you please include the exception details? e.g. what is written to
std::cerr? These messages are usually pretty informative...
Cheers, Dan
On 28 December 2010 12:50, Ali Habib <ali.mahmoud.habib at gmail.com> wrote:
> Dear All,
> I used the following code to read DICOM file , but it always enter the catch
> , am I forget something
>
> typedef signed short InputPixelType;
> const unsigned int InputDimension = 2;
> typedef itk::Image< InputPixelType, InputDimension > InputImageType;
> typedef itk::ImageFileReader< InputImageType > ReaderType;
> typedef InputImageType::SizeType SizeType;
> ReaderType::Pointer reader = ReaderType::New();
> reader->SetFileName( "IM35" );
> typedef itk::GDCMImageIO ImageIOType;
> ImageIOType::Pointer gdcmImageIO = ImageIOType::New();
> reader->SetImageIO( gdcmImageIO );
> try
> {
> reader->Update();
> }
> catch (itk::ExceptionObject & e)
> {
> std::cerr << "exception in file reader " << std::endl;
> std::cerr << e << std::endl;
> // return EXIT_FAILURE;
> }
> any suggestion please
> _____________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Kitware offers ITK Training Courses, for more information visit:
> http://www.kitware.com/products/protraining.html
>
> Please keep messages on-topic and check the ITK FAQ at:
> http://www.itk.org/Wiki/ITK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.itk.org/mailman/listinfo/insight-users
>
>
More information about the Insight-users
mailing list