[Insight-users] Image size is null
Sylvain Bernhardt
sylvainb at ece.ubc.ca
Sun Feb 26 18:40:52 EST 2012
Hi all,
I would like to retrieve the size of a 2D image as follow:
ImageType::Pointer img = somereader->GetImage();
itk::Size<2> imgSize = img->GetLargestPossibleRegion().GetSize();
But during the debug in VisualStudio, imgSize[0] and imgSize[1] appears
to be null. Same if I do a std::cout.
However, I know the image is well read as it is correctly displayed
later on in the code with a itkImageToVTKImageFilter.
Thanks for helping me out,
S.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.itk.org/pipermail/insight-users/attachments/20120226/aa5d1d7b/attachment.htm>
More information about the Insight-users
mailing list