[ITK-users] MeanSquaresImageToImageMetricv4 with Vector images
Sureerat Reaungamornrat
sureerat.r at gmail.com
Mon Jul 7 16:24:53 EDT 2014
Dear All,
I tested MeanSquaresImageToImageMetricv4 with vector images using
following file.
...\Modules\Registration\Metricsv4\test\itkMeanSquaresImageToImageMetricv4OnVectorTest.cxx
First, I changed the vector image declaration to
const unsigned int vectorLength = 25;
typedef itk::Vector<double, vectorLength> VectorType;
typedef itk::Image< VectorType, imageDimensionality > ImageType;
And I got the following compilation error:
error LNK2001: unresolved external symbol "public: static class
itk::Vector<double,25> const itk::NumericTraits<class
itk::Vector<double,25> >::Zero".
Would anyone know what the source of this compilation error or how to fix
this? If I commented out 'New()' as follow
MetricType::Pointer metric;// = MetricType::New();
The program can be compiled.
Second, I tested the metric with itk::VectorImage whose elements are
itk::VariableLengthVector.
typedef itk::VectorImage<double, imageDimensionality> ImageType;
typedef ImageType::PixelType VectorType;
I got compilation error as follow
error : 'Length': is not a member of itk::VariableLengthVector<TValueType>
error : 'Length': undeclared identifier
Both are from itkPixelTraits.h
Where does the ImageToImageMetricv4 use PixelTraits? Is there a way to
fix this?
Thank you very much for time and help,
Best regards,
Ja
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/insight-users/attachments/20140707/0c580f30/attachment.html>
More information about the Insight-users
mailing list