[Insight-users] reading and writing volume image

Kishore Mosaliganti kishoreraom at gmail.com
Wed May 26 11:29:01 EDT 2010


hi Shoosh,

You have not set the output of the reader as your InputFile and
instead allocated a new image pointer.

Replace
  InputImageType::Pointer InputFile = InputImageType::New();

with

  InputImageType::Pointer InputFile = reader->GetOutput();


Kishore



2010/5/26 shoosh moosh <babygirl_25 at hotmail.com>:
> Hi,
> I'm trying to read a 3D nifti image, change it's spacing, then rewrite it as
> a new volume. There is no runtime error with my code, but there is a logical
> error that produces a messed up output image. Can some one help me? The code
> is attached.
> Regards
>
> ________________________________
> Hotmail: Powerful Free email with security by Microsoft. Get it now.
> _____________________________________
> 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