diff --git a/Code/Projections/otbGenericRSTransform.txx b/Code/Projections/otbGenericRSTransform.txx index 2c8517dd24649abcd0d8e64872e258d4e194f122..5cbb86a5ff3404c9d36214103bd05ab355da3ba0 100644 --- a/Code/Projections/otbGenericRSTransform.txx +++ b/Code/Projections/otbGenericRSTransform.txx @@ -117,7 +117,7 @@ GenericRSTransform<TScalarType, NInputDimensions, NOutputDimensions> InverseMapProjectionType; typename InverseMapProjectionType::Pointer mapTransform = InverseMapProjectionType::New(); mapTransform->SetWkt(m_InputProjectionRef); - if (mapTransform->GetMapProjection() != NULL) + if (mapTransform->GetMapProjection()->GetMapProjection() != NULL) { m_InputTransform = mapTransform.GetPointer(); inputTransformIsMap = true; @@ -195,7 +195,7 @@ GenericRSTransform<TScalarType, NInputDimensions, NOutputDimensions> OutputSpaceDimension> ForwardMapProjectionType; typename ForwardMapProjectionType::Pointer mapTransform = ForwardMapProjectionType::New(); mapTransform->SetWkt(m_OutputProjectionRef); - if (mapTransform->GetMapProjection() != NULL) + if (mapTransform->GetMapProjection()->GetMapProjection() != NULL) { m_OutputTransform = mapTransform.GetPointer(); outputTransformIsMap = true;