Fail to retrieve the pixel spacing from image metadata.
Mantis Issue 221, reported by ebarthelet, assigned to echristophe, created: 2011-01-08
Both methods GetXPixelSpacing() and GetYPixelSpacing() of class otb::ImageMetadataInterfaceBase are searching for the key "pixel_spacing" in the ossimKeywordList, a key that does not exist (anymore ?). As a consequence, both methods returns systematically 0 !! I suggest to search for the keys "meters_per_pixel_x" and "meters_per_pixel_y".
1294538750 - christopFor reference for OTB team: this problem should have been detected when creating the test ioTvImageMetadataInterfaceBaseTest_TSX1dims and setting up the baseline file: OTB-Data/Baseline/OTB/Files/ioTvImageMetadataInterfaceBase_TSX1dims.txt
This file contains the clearly invalid values: NumberOfBands: 0 XPixelSpacing: 0 YPixelSpacing: 0
1294550237 - christopThanks for the report! The bug should now be fixed with http://hg.orfeo-toolbox.org/OTB/rev/e3f2715cd37c
Let us know if there are still some problems.
1372256381 - grizonnetmI close this bug as it was resolved in 2011