diff --git a/Core/Main/itkElastixRegistrationMethod.hxx b/Core/Main/itkElastixRegistrationMethod.hxx index 450886e79..b964e0c0e 100644 --- a/Core/Main/itkElastixRegistrationMethod.hxx +++ b/Core/Main/itkElastixRegistrationMethod.hxx @@ -81,13 +81,6 @@ ElastixRegistrationMethod::GenerateData() using elx::LibUtilities::RetrievePixelTypeParameterValue; using elx::LibUtilities::SetParameterValueAndWarnOnOverride; - // Force compiler to instantiate the image dimensions, otherwise we may get - // Undefined symbols for architecture x86_64: - // "elx::ElastixRegistrationMethod >::FixedImageDimension" - // on some platforms. - const unsigned int fixedImageDimension = FixedImageDimension; - const unsigned int movingImageDimension = MovingImageDimension; - DataObjectContainerPointer fixedMaskContainer = nullptr; DataObjectContainerPointer movingMaskContainer = nullptr; DataObjectContainerPointer resultImageContainer = nullptr; @@ -184,9 +177,9 @@ ElastixRegistrationMethod::GenerateData() m_EnableOutput && m_LogToConsole, static_cast(m_LogLevel)); - const auto fixedImageDimensionString = std::to_string(fixedImageDimension); + const auto fixedImageDimensionString = std::to_string(FixedImageDimension); const auto fixedImagePixelTypeString = elx::PixelTypeToString(); - const auto movingImageDimensionString = std::to_string(movingImageDimension); + const auto movingImageDimensionString = std::to_string(MovingImageDimension); const std::vector fixedInputImages = GetInputImages("FixedImage"); const std::vector movingInputImages = GetInputImages("MovingImage"); diff --git a/Core/Main/itkTransformixFilter.hxx b/Core/Main/itkTransformixFilter.hxx index 8d4594778..569ff99c7 100644 --- a/Core/Main/itkTransformixFilter.hxx +++ b/Core/Main/itkTransformixFilter.hxx @@ -68,12 +68,6 @@ TransformixFilter::GenerateData() using elx::LibUtilities::RetrievePixelTypeParameterValue; using elx::LibUtilities::SetParameterValueAndWarnOnOverride; - // Force compiler to instantiate the image dimension, otherwise we may get - // Undefined symbols for architecture x86_64: - // "elastix::TransformixFilter >::MovingImageDimension" - // on some platforms. - const unsigned int movingImageDimension = MovingImageDimension; - if (this->IsEmpty(this->GetMovingImage()) && m_FixedPointSetFileName.empty() && !m_ComputeSpatialJacobian && !m_ComputeDeterminantOfSpatialJacobian && !m_ComputeDeformationField) { @@ -246,7 +240,7 @@ TransformixFilter::GenerateData() } } - const auto movingImageDimensionString = std::to_string(movingImageDimension); + const auto movingImageDimensionString = std::to_string(MovingImageDimension); const auto movingImagePixelTypeString = elx::PixelTypeToString(); // Set pixel types from input image, override user settings