Commit ec03b4f0 authored by Manuel Grizonnet's avatar Manuel Grizonnet
Browse files

ENH:update example to avoid scramble output in SG

parent d85fb29b
...@@ -53,11 +53,11 @@ ADD_TEST(trTeOBIAShapeAttributeComputationTest ${EXE_TESTS} ...@@ -53,11 +53,11 @@ ADD_TEST(trTeOBIAShapeAttributeComputationTest ${EXE_TESTS}
) )
ADD_TEST(trTeOBIARadiometricAttributesLabelMapFilterTest ${EXE_TESTS} ADD_TEST(trTeOBIARadiometricAttributesLabelMapFilterTest ${EXE_TESTS}
--compare-image ${TOL} ${BASELINE}/OBIARadiometricAttributes.tif --compare-image ${TOL} ${BASELINE}/OBIARadiometricAttributes.png
${TEMP}/OBIARadiometricAttributes.tif ${TEMP}/OBIARadiometricAttributes.png
RadiometricAttributesLabelMapFilterExample RadiometricAttributesLabelMapFilterExample
${INPUTDATA}/qb_RoadExtract.tif ${INPUTDATA}/qb_RoadExtract.tif
${TEMP}/OBIARadiometricAttributes.tif ${TEMP}/OBIARadiometricAttributes.png
${TEMP}/qb_RoadExtract_Radiometry_pretty.png ${TEMP}/qb_RoadExtract_Radiometry_pretty.png
STATS::Band1::Mean STATS::Band1::Mean
0 0
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
// Software Guide : BeginCommandLineArgs // Software Guide : BeginCommandLineArgs
// INPUTS: {qb_RoadExtract.tif} // INPUTS: {qb_RoadExtract.tif}
// OUTPUTS: {OBIARadiometricAttribute1.tif}, {qb_ExtractRoad_Radiometry_pretty.jpg} // OUTPUTS: {OBIARadiometricAttribute1.png}, {qb_ExtractRoad_Radiometry_pretty.jpg}
// STATS::Band1::Mean 0 0.5 16 16 50 1.0 // STATS::Band1::Mean 0 0.5 16 16 50 1.0
// Software Guide : EndCommandLineArgs // Software Guide : EndCommandLineArgs
...@@ -86,15 +86,17 @@ int main(int argc, char * argv[]) ...@@ -86,15 +86,17 @@ int main(int argc, char * argv[])
// Labeled image type // Labeled image type
typedef unsigned short LabelType; typedef unsigned short LabelType;
typedef unsigned char MaskPixelType;
typedef double PixelType; typedef double PixelType;
typedef otb::Image<LabelType, Dimension> LabeledImageType; typedef otb::Image<LabelType, Dimension> LabeledImageType;
typedef otb::Image<MaskPixelType, Dimension> MaskImageType;
typedef otb::Image<PixelType, Dimension> ImageType; typedef otb::Image<PixelType, Dimension> ImageType;
typedef otb::VectorImage<PixelType, Dimension> VectorImageType; typedef otb::VectorImage<PixelType, Dimension> VectorImageType;
typedef otb::VectorImage<unsigned char, Dimension> OutputVectorImageType; typedef otb::VectorImage<unsigned char, Dimension> OutputVectorImageType;
typedef otb::ImageFileReader<LabeledImageType> LabeledReaderType; typedef otb::ImageFileReader<LabeledImageType> LabeledReaderType;
typedef otb::ImageFileReader<ImageType> ReaderType; typedef otb::ImageFileReader<ImageType> ReaderType;
typedef otb::ImageFileReader<VectorImageType> VectorReaderType; typedef otb::ImageFileReader<VectorImageType> VectorReaderType;
typedef otb::ImageFileWriter<LabeledImageType> WriterType; typedef otb::ImageFileWriter<MaskImageType> WriterType;
typedef otb::ImageFileWriter<OutputVectorImageType> VectorWriterType; typedef otb::ImageFileWriter<OutputVectorImageType> VectorWriterType;
typedef otb::VectorRescaleIntensityImageFilter typedef otb::VectorRescaleIntensityImageFilter
<VectorImageType, OutputVectorImageType> VectorRescalerType; <VectorImageType, OutputVectorImageType> VectorRescalerType;
...@@ -120,7 +122,7 @@ int main(int argc, char * argv[]) ...@@ -120,7 +122,7 @@ int main(int argc, char * argv[])
typedef otb::AttributesMapOpeningLabelMapFilter<LabelMapType> typedef otb::AttributesMapOpeningLabelMapFilter<LabelMapType>
OpeningLabelMapFilterType; OpeningLabelMapFilterType;
typedef itk::LabelMapToBinaryImageFilter<LabelMapType, typedef itk::LabelMapToBinaryImageFilter<LabelMapType,
LabeledImageType> MaskImageType>
LabelMapToBinaryImageFilterType; LabelMapToBinaryImageFilterType;
typedef otb::MultiChannelRAndNIRIndexImageFilter<VectorImageType, typedef otb::MultiChannelRAndNIRIndexImageFilter<VectorImageType,
ImageType> NDVIImageFilterType; ImageType> NDVIImageFilterType;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment