From 03ed384ba197823bdc9a6669a2cbcd38e553eb2a Mon Sep 17 00:00:00 2001 From: Mickael Savinaud <mickael.savinaud@c-s.fr> Date: Mon, 19 Mar 2012 15:05:32 +0100 Subject: [PATCH] [BUG] resolve problem with computation of UTM hemisphere when we initialize app UTM parameters --- .../otbWrapperMapProjectionParametersHandler.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Code/ApplicationEngine/otbWrapperMapProjectionParametersHandler.cxx b/Code/ApplicationEngine/otbWrapperMapProjectionParametersHandler.cxx index 23343511f4..46e49b1681 100644 --- a/Code/ApplicationEngine/otbWrapperMapProjectionParametersHandler.cxx +++ b/Code/ApplicationEngine/otbWrapperMapProjectionParametersHandler.cxx @@ -217,6 +217,7 @@ void MapProjectionParametersHandler::InitializeUTMParameters(Application::Pointe // Compute the Origin lat/long coordinate typedef otb::ImageToGenericRSOutputParameters<FloatVectorImageType> OutputParametersEstimatorType; OutputParametersEstimatorType::Pointer genericRSEstimator = OutputParametersEstimatorType::New(); + genericRSEstimator->SetInput(app->GetParameterImage(imageKey)); genericRSEstimator->SetOutputProjectionRef(otb::GeoInformationConversion::ToWKT(4326)); genericRSEstimator->Compute(); @@ -225,7 +226,7 @@ void MapProjectionParametersHandler::InitializeUTMParameters(Application::Pointe genericRSEstimator->GetOutputOrigin()[1]); // Update the UTM Gui fields app->SetParameterInt(zoneKey.str(), zone); - if(genericRSEstimator->GetOutputOrigin()[0] > 0.) + if(genericRSEstimator->GetOutputOrigin()[1] > 0.) { app->EnableParameter(hemKey.str()); } -- GitLab