[Insight-users] Fwd: bmp series reader
Luis Ibanez
luis.ibanez at kitware.com
Thu Aug 4 18:05:39 EDT 2005
Hi Diego,
The image that you sent me is a JPEG image.
You said that you are having problems with BMP not JPEG.
Please send me the BMP image that is giving you trouble.
Thanks
Luis
--------------------
Diego Parada wrote:
> Hi Luis;
>
> The images BMP can be read in other applications.
>
> Next i send a image of the set that fail.
>
> Thanks;
>
>
> 2005/7/30, Luis Ibanez <luis.ibanez at kitware.com
> <mailto:luis.ibanez at kitware.com>>:
>
>
> Hi Diego,
>
> Thanks for your clarifications.
>
> It is very suspicious that your program works when
> reading BMP images of 16 and 24 bits, but fails
> when reading BMP images of 8 bits.
>
> Can you read those BMP 8-bit images with other
> applications ?
>
> Is there a chance that you could send us one of
> the BMP images that are failing, so we can run
> tests on it ?
>
>
> Please let us know,
>
>
> Thanks
>
>
> Luis
>
>
> -------------------
> Diego Parada wrote:
> > Hi Luis;
> >
> > Answering your questión I select a) It crashed at run time, but this
> > happens when I try load bmp images of 8 bits, whith bmp images of
> 16 or
> > 24 bitt the application runs sucessfully.
> > All the bmp's have the same size and they belong to the same CT.
> >
> >
> > 2005/7/27, Luis Ibanez <luis.ibanez at kitware.com
> <mailto:luis.ibanez at kitware.com>
> > <mailto:luis.ibanez at kitware.com <mailto:luis.ibanez at kitware.com>>>:
> >
> >
> > Hi Diego,
> >
> > When you say that your program didn't run
> > successfully do you mean that:
> >
> > a) It crashed at run time ?
> > b) It produced a segmentation fault ?
> > c) It produced an "abort" message ?
> > d) It read the image but the pixel
> > content is wrong ?
> >
> > BTW,
> > Do you have a series of .bmp images
> > and you want to convert them to a
> > series of .png ?
> >
> > Are all the .bmp of the same size ?
> > Do they actually belong to a 3D volume ?
> >
> >
> > Please let us know,
> >
> >
> > Thansk
> >
> >
> > Luis
> >
> >
> >
> > --------------------
> > Diego Parada wrote:
> > >
> > >
> > > ---------- Forwarded message ----------
> > > From: *Diego Parada* < icebishop at gmail.com
> <mailto:icebishop at gmail.com>
> > <mailto: icebishop at gmail.com <mailto:icebishop at gmail.com>>
> <mailto:icebishop at gmail.com <mailto:icebishop at gmail.com>
> > <mailto:icebishop at gmail.com <mailto:icebishop at gmail.com>>>>
> > > Date: 27-jul-2005 12:33
> > > Subject: bmp series reader
> > > To: insight-users at itk.org <mailto:insight-users at itk.org>
> <mailto:insight-users at itk.org <mailto:insight-users at itk.org>>
> > <mailto: insight-users at itk.org <mailto:insight-users at itk.org>
> <mailto:insight-users at itk.org <mailto:insight-users at itk.org>>>.
> > >
> > > Hello.
> > >
> > > I like read a bmp series, the code is:
> > >
> > > typedef itk::RGBPixel< unsigned char > PixelType;
> > > const unsigned int Dimension = 3;
> > > typedef itk::Image< PixelType, Dimension > ImageType;
> > >
> > > typedef itk::ImageSeriesReader< ImageType > ReaderType;
> > > typedef itk::ImageFileWriter< ImageType > WriterType;
> > > typedef itk::NumericSeriesFileNames NameGeneratorType;
> > >
> > > ReaderType::Pointer reader = ReaderType::New();
> > > WriterType::Pointer writer = WriterType::New();
> > > NameGeneratorType::Pointer nameGenerator =
> > NameGeneratorType::New();
> > >
> > > nameGenerator->SetStartIndex( 2 );
> > > nameGenerator->SetEndIndex( 7 );
> > > nameGenerator->SetIncrementIndex( 1 );
> > >
> > > nameGenerator->SetSeriesFormat( "IRM%03d.bmp" );
> > >
> > > reader->SetImageIO( itk::BMPImageIO::New() );
> > >
> > > reader->SetFileNames( nameGenerator->GetFileNames() );
> > >
> > > try
> > > {
> > > reader->Update();
> > > }
> > > catch( itk::ExceptionObject & excp )
> > > {
> > > std::cerr << "Error reading the series " << std::endl;
> > > std::cerr << excp << std::endl;
> > > }
> > > reader->Delete();
> > > writer->Delete();
> > > nameGenerator->Delete();
> > >
> > > this compile whitout errors, but no run succefully.
> > >
> > > I like how can convert bmp to png in runtime
> > >
> > > thanks
> > >
> > >
> > > --
> > > Diego Armando Parada Cuervo
> > > Estudiante de Ingeniería de Sistemas y Computación
> > > Universidad Pedagógica y Tecnológica de Colombia
> > >
> > > --
> > > Diego Armando Parada Cuervo
> > > Estudiante de Ingeniería de Sistemas y Computación
> > > Universidad Pedagógica y Tecnológica de Colombia
> > >
> > >
> > >
> >
> ------------------------------------------------------------------------
> >
> > >
> > > _______________________________________________
> > > Insight-users mailing list
> > > Insight-users at itk.org <mailto:Insight-users at itk.org>
> <mailto:Insight-users at itk.org <mailto:Insight-users at itk.org>>
> > > http://www.itk.org/mailman/listinfo/insight-users
> >
> >
> >
> >
> > --
> > Diego Armando Parada Cuervo
> > Estudiante de Ingeniería de Sistemas y Computación
> > Universidad Pedagógica y Tecnológica de Colombia
>
>
>
>
> --
> Diego Armando Parada Cuervo
> Estudiante de Ingeniería de Sistemas y Computación
> Universidad Pedagógica y Tecnológica de Colombia
> ------------------------------------------------------------------------
>
More information about the Insight-users
mailing list