From 4094123bff41a82a050e34c38b9e5e2a71ed948f Mon Sep 17 00:00:00 2001
From: Julien Malik <julien.malik@c-s.fr>
Date: Tue, 20 Sep 2011 11:49:40 +0200
Subject: [PATCH] ENH: most parameters are not mandatory for
 HyperspectralUnmixing

---
 Applications/Hyperspectral/otbHyperspectralUnmixing.cxx | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/Applications/Hyperspectral/otbHyperspectralUnmixing.cxx b/Applications/Hyperspectral/otbHyperspectralUnmixing.cxx
index 39737f3a50..8910c5bcdd 100644
--- a/Applications/Hyperspectral/otbHyperspectralUnmixing.cxx
+++ b/Applications/Hyperspectral/otbHyperspectralUnmixing.cxx
@@ -122,19 +122,25 @@ private:
     AddChoice("dr.pca", "PCA");
     AddChoice("dr.mnf", "MNF");
     AddChoice("dr.napca", "NAPCA");
+    MandatoryOff("dr");
 
     AddParameter(ParameterType_Int, "ne", "Number of endmembers");
     SetParameterInt("ne", 1);
+    MandatoryOff("ne");
 
     AddParameter(ParameterType_Choice, "de", "Dimensionnality estimation");
+    MandatoryOff("de");
     AddChoice("de.elm", "ELM (Eigen Value Likelihood Estimation)");
 
     AddParameter(ParameterType_Choice, "ee", "Endmembers estimation method");
+    MandatoryOff("ee");
     AddChoice("ee.vca", "VCA (Vertex Component Analysis)");
 
     AddParameter(ParameterType_InputImage, "ie", "Input endmembers image");
+    MandatoryOff("ie");
 
     AddParameter(ParameterType_Choice, "ua", "Unmixing algorithm");
+    MandatoryOff("ua");
     AddChoice("ua.none", "None");
     AddChoice("ua.ucls", "UCLS");
     AddChoice("ua.isra", "ISRA");
@@ -142,6 +148,7 @@ private:
     AddChoice("ua.fcls", "FCLS");
 
     AddParameter(ParameterType_OutputImage, "oe", "Output Endmembers");
+    MandatoryOff("oe");
   }
 
   void DoUpdateParameters()
-- 
GitLab