Transform physical point refactoring

I was trying to refactor Ultrasound remote module to avoid nodiscard warnings, only to end up with non-compiling code. The error messages are below. @Niels_Dekker I assume that some recent transform physical point overloads should be added to Ultrasound?

Build started...
1>------ Build started: Project: swig, Configuration: RelWithDebInfo x64 ------
2>------ Build started: Project: castxml, Configuration: RelWithDebInfo x64 ------
3>------ Build started: Project: UltrasoundHeaderTestClean, Configuration: RelWithDebInfo x64 ------
4>------ Skipped Build: Project: RUN_TESTS, Configuration: RelWithDebInfo x64 ------
4>Project not selected to build for this solution configuration 
5>------ Skipped Build: Project: NightlyMemoryCheck, Configuration: RelWithDebInfo x64 ------
5>Project not selected to build for this solution configuration 
6>------ Skipped Build: Project: Nightly, Configuration: RelWithDebInfo x64 ------
6>Project not selected to build for this solution configuration 
7>------ Build started: Project: ITKData, Configuration: RelWithDebInfo x64 ------
8>------ Skipped Build: Project: Experimental, Configuration: RelWithDebInfo x64 ------
8>Project not selected to build for this solution configuration 
9>------ Skipped Build: Project: Continuous, Configuration: RelWithDebInfo x64 ------
9>Project not selected to build for this solution configuration 
10>------ Build started: Project: ClangFormat, Configuration: RelWithDebInfo x64 ------
11>------ Build started: Project: UltrasoundTestDriver, Configuration: RelWithDebInfo x64 ------
12>------ Build started: Project: UltrasoundHeaderTest1, Configuration: RelWithDebInfo x64 ------
13>------ Build started: Project: UltrasoundCastXML, Configuration: RelWithDebInfo x64 ------
14>------ Skipped Build: Project: ITKHeaderTests, Configuration: RelWithDebInfo x64 ------
14>Project not selected to build for this solution configuration 
12>Generating test/UltrasoundHeaderTest1.cxx
12>UltrasoundHeaderTest1.cxx
11>itkBlockMatchingBayesianRegularizationDisplacementCalculatorTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkAnalyticSignalImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
12>UltrasoundHeaderTest1.vcxproj -> C:\Dev\ITK-py11\Wrapping\Generators\Python\itk\UltrasoundHeaderTest1.exe
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(148,1): message : while compiling class template member function 'void itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingBayesianRegularizationDisplacementCalculatorTest.cxx(61,40): message : see reference to class template instantiation 'itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11>        with
11>        [
11>            TValue=itk::ImageBase<2>::SpacingValueType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>itkBlockMatchingImageRegistrationMethodTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkAttenuationImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(148,1): message : while compiling class template member function 'void itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingImageRegistrationMethodTest.cxx(57,40): message : see reference to class template instantiation 'itk::BlockMatching::SearchRegionImageInitializer<InputImageType,InputImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11>        with
11>        [
11>            TValue=itk::ImageBase<2>::SpacingValueType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingSearchRegionImageInitializer.hxx(166,11): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>itkBlockMatchingMultiResolutionImageRegistrationMethodTest.cxx
13>Generating C:/Dev/ITK-py11/Wrapping/castxml_inputs/itkBModeImageFilter.xml
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): error C2679: binary '=': no operator found which takes a right-hand operand of type 'const double' (or there is no acceptable conversion)
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : could be 'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(itk::Point<itk::ImageBase<2>::PointValueType,2> &&)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(301,1): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const itk::Point<itk::ImageBase<2>::PointValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(134,3): message : or       'itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator =(const double [])'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(576,14): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, const double)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,1): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(594,34): message : see reference to function template instantiation 'void itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &,itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,1): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,13): message : see reference to function template instantiation 'itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> itk::ImageBase<2>::TransformIndexToPhysicalPoint<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Index<2> &) const' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(90,1): message : while compiling class template member function 'void itk::BlockMatching::MultiResolutionFixedSearchRegionImageSource<InputImageType,InputImageType,DisplacementImageType>::DynamicThreadedGenerateData(const itk::ImageRegion<2> &)'
11>C:\Dev\ITKUltrasound\test\itkBlockMatchingMultiResolutionImageRegistrationMethodTest.cxx(68,52): message : see reference to class template instantiation 'itk::BlockMatching::MultiResolutionFixedSearchRegionImageSource<InputImageType,InputImageType,DisplacementImageType>' being compiled
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): error C2679: binary '+=': no operator found which takes a right-hand operand of type 'T' (or there is no acceptable conversion)
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(153,3): message : could be 'const itk::Point<itk::ImageBase<2>::PointValueType,2> &itk::Point<itk::ImageBase<2>::PointValueType,2>::operator +=(const itk::Vector<itk::ImageBase<2>::SpacingValueType,2> &)'
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkImageBase.h(579,16): message : while trying to match the argument list '(itk::Point<itk::ImageBase<2>::PointValueType,2>, T)'
11>        with
11>        [
11>            T=itk::SpacePrecisionType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): error C2440: 'static_cast': cannot convert from 'const itk::Point<itk::ImageBase<2>::PointValueType,2>' to 'TValue'
11>        with
11>        [
11>            TValue=itk::ImageBase<2>::SpacingValueType
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkFixedArray.h(220,17): message : No user-defined-conversion operator available that can perform this conversion, or the operator cannot be called
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(93,1): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITK-git\Modules\Core\Common\include\itkPoint.h(92,16): message : see reference to function template instantiation 'itk::FixedArray<T,2>::FixedArray<TCoordRep>(const itk::FixedArray<TCoordRep,2> &)' being compiled
11>        with
11>        [
11>            T=itk::ImageBase<2>::SpacingValueType,
11>            TCoordRep=itk::Point<itk::ImageBase<2>::PointValueType,2>
11>        ]
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,1): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>C:\Dev\ITKUltrasound\include\itkBlockMatchingMultiResolutionFixedSearchRegionImageSource.hxx(126,13): message : see reference to function template instantiation 'itk::Point<itk::ImageBase<2>::PointValueType,2>::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>>(const itk::Point<itk::Point<itk::ImageBase<2>::PointValueType,2>,2> &)' being compiled
11>Generating Code...
11>Done building project "UltrasoundTestDriver.vcxproj" -- FAILED.
Build has been canceled.
========== Elapsed 12:26 PM ==========

Thanks for asking @dzenanz ! Honestly I find the compile errors quite hard to digest, but at least it appears to me that a template keyword should be added here:

I think it should say:

point = outputPtr->template TransformIndexToPhysicalPoint<typename MovingImageType::PointType>(index);

The problem here seems to be that the compiler may not assume that this instance of TransformIndexToPhysicalPoint is a member function template, because it does not know the type of outputPtr. I mean, outputPtr could be any type, depending on template arguments of the filter, so TransformIndexToPhysicalPoint could then also be “anything”. So you’d have to tell the compiler it’s a template.

HTH, Niels

PS Same here, of course, missing a template keyword:

1 Like

Thanks for taking a look. Adding template as you suggested does not help. The error message is the same. And it is interesting, too: cannot convert from const double to point[i], which makes no sense. And this doesn’t even involve special coordinates images! So I am essentially giving up on this refactoring.

point = outputPtr->template TransformIndexToPhysicalPoint<typename MovingImageType::PointType>(index);

Maybe something like:

point = outputPtr->template TransformIndexToPhysicalPoint<typename MovingImageType::PointValueType>(index);

or

point = outputPtr->template TransformIndexToPhysicalPoint<double>(index);

Not tested, just guessing.

I have now code like (not checking “is inside” is the intention):

  itk::Point<float, 3> point;
  point[0] = hit.getX();
  point[1] = hit.getY();
  point[2] = hit.getZ();
#if ITK_VERSION_MAJOR >= 5
  const auto index = image->template TransformPhysicalPointToContinuousIndex<float>(point);
#else
  itk::ContinuousIndex<float, 3> index;
  image->TransformPhysicalPointToContinuousIndex(point, index);
#endif

In itkImageBase.h:

   template <typename TCoordRep>
   [[nodiscard]] Point<TCoordRep, VImageDimension>
   TransformIndexToPhysicalPoint(const IndexType & index) const
   {
     Point<TCoordRep, VImageDimension> point;
     TransformIndexToPhysicalPoint(index, point);
     return point;
   }
3 Likes

Using PointValueType instead of PointType gets it compiling. Thanks @mihail.isakov :eagle::eye:

3 Likes