diff --git a/include/rtkMechlemOneStepSpectralReconstructionFilter.h b/include/rtkMechlemOneStepSpectralReconstructionFilter.h index 10e5b7b1d..693648ec0 100644 --- a/include/rtkMechlemOneStepSpectralReconstructionFilter.h +++ b/include/rtkMechlemOneStepSpectralReconstructionFilter.h @@ -168,16 +168,17 @@ class ITK_TEMPLATE_EXPORT MechlemOneStepSpectralReconstructionFilter /** SFINAE type alias, depending on whether a CUDA image is used. */ using CPUOutputImageType = typename itk::Image; #ifdef RTK_USE_CUDA - typedef typename std::conditional< - std::is_same::value, - itk::Image, TOutputImage::ImageDimension>, - itk::CudaImage, TOutputImage::ImageDimension>>::type THessiansImage; + typedef + typename std::conditional::value, + itk::Image, TOutputImage::ImageDimension>, + itk::CudaImage, + TOutputImage::ImageDimension>>::type HessiansImageType; typedef typename std::conditional::value, itk::Image, itk::CudaImage>::type SingleComponentImageType; #else - using THessiansImage = + using HessiansImageType = typename itk::Image, TOutputImage::ImageDimension>; using SingleComponentImageType = typename itk::Image; #endif @@ -194,16 +195,16 @@ class ITK_TEMPLATE_EXPORT MechlemOneStepSpectralReconstructionFilter CudaForwardProjectionImageFilter>:: type CudaSingleComponentForwardProjectionImageFilterType; typedef typename std::conditional::value, - BackProjectionImageFilter, - CudaBackProjectionImageFilter>::type + BackProjectionImageFilter, + CudaBackProjectionImageFilter>::type CudaHessiansBackProjectionImageFilterType; # else using WeidingerForwardModelType = WeidingerForwardModelImageFilter; using CudaSingleComponentForwardProjectionImageFilterType = JosephForwardProjectionImageFilter; - using CudaHessiansBackProjectionImageFilterType = BackProjectionImageFilter; + using CudaHessiansBackProjectionImageFilterType = BackProjectionImageFilter; # endif - using TGradientsImage = TOutputImage; + using GradientsImageType = TOutputImage; #endif using ForwardProjectionType = typename Superclass::ForwardProjectionType; @@ -212,22 +213,22 @@ class ITK_TEMPLATE_EXPORT MechlemOneStepSpectralReconstructionFilter #if !defined(ITK_WRAPPING_PARSER) /** Filter type alias */ using ExtractPhotonCountsFilterType = itk::ExtractImageFilter; - using AddFilterType = itk::AddImageFilter; + using AddFilterType = itk::AddImageFilter; using SingleComponentForwardProjectionFilterType = rtk::ForwardProjectionImageFilter; using ForwardProjectionFilterType = rtk::ForwardProjectionImageFilter; - using GradientsBackProjectionFilterType = rtk::BackProjectionImageFilter; - using HessiansBackProjectionFilterType = rtk::BackProjectionImageFilter; + using GradientsBackProjectionFilterType = rtk::BackProjectionImageFilter; + using HessiansBackProjectionFilterType = rtk::BackProjectionImageFilter; using NesterovFilterType = rtk::NesterovUpdateImageFilter; using SingleComponentImageSourceType = rtk::ConstantImageSource; using MaterialProjectionsSourceType = rtk::ConstantImageSource; - using GradientsSourceType = rtk::ConstantImageSource; - using HessiansSourceType = rtk::ConstantImageSource; - using SQSRegularizationType = rtk::SeparableQuadraticSurrogateRegularizationImageFilter; - using AddMatrixAndDiagonalFilterType = rtk::AddMatrixAndDiagonalImageFilter; - using NewtonFilterType = rtk::GetNewtonUpdateImageFilter; + using GradientsSourceType = rtk::ConstantImageSource; + using HessiansSourceType = rtk::ConstantImageSource; + using SQSRegularizationType = rtk::SeparableQuadraticSurrogateRegularizationImageFilter; + using AddMatrixAndDiagonalFilterType = rtk::AddMatrixAndDiagonalImageFilter; + using NewtonFilterType = rtk::GetNewtonUpdateImageFilter; using MultiplyFilterType = itk::MultiplyImageFilter; - using MultiplyGradientFilterType = itk::MultiplyImageFilter; + using MultiplyGradientFilterType = itk::MultiplyImageFilter; #endif /** Pass the geometry to all filters needing it */ diff --git a/include/rtkMechlemOneStepSpectralReconstructionFilter.hxx b/include/rtkMechlemOneStepSpectralReconstructionFilter.hxx index 960d1eeaf..9b1eec3b4 100644 --- a/include/rtkMechlemOneStepSpectralReconstructionFilter.hxx +++ b/include/rtkMechlemOneStepSpectralReconstructionFilter.hxx @@ -65,10 +65,10 @@ MechlemOneStepSpectralReconstructionFilterSetConstant(itk::NumericTraits::One); m_GradientsSource->SetConstant( itk::NumericTraits:: - TGradientsImage::PixelType>::ZeroValue()); + GradientsImageType::PixelType>::ZeroValue()); m_HessiansSource->SetConstant( itk::NumericTraits:: - THessiansImage::PixelType>::ZeroValue()); + HessiansImageType::PixelType>::ZeroValue()); } template @@ -204,7 +204,7 @@ typename MechlemOneStepSpectralReconstructionFilter::THessiansImage; + typename MechlemOneStepSpectralReconstructionFilter::HessiansImageType; // Declare the pointer typename MechlemOneStepSpectralReconstructionFilter:: @@ -482,8 +482,8 @@ MechlemOneStepSpectralReconstructionFilterUpdate(); m_HessiansBackProjectionFilter->Update(); - typename TGradientsImage::Pointer gBP = m_GradientsBackProjectionFilter->GetOutput(); - typename THessiansImage::Pointer hBP = m_HessiansBackProjectionFilter->GetOutput(); + typename GradientsImageType::Pointer gBP = m_GradientsBackProjectionFilter->GetOutput(); + typename HessiansImageType::Pointer hBP = m_HessiansBackProjectionFilter->GetOutput(); gBP->DisconnectPipeline(); hBP->DisconnectPipeline(); m_GradientsBackProjectionFilter->SetInput(gBP);