[Insight-users] numeric traits for the std::complex < >
Miller, James V (Research)
millerjv at crd.ge.com
Tue May 10 08:30:08 EDT 2005
Suyash,
I am guessing your solution was to provide a specialization for
NumericTraits<std::complex<double> >. Something like...
template <>
class NumericTraits<std::complex<double> > : public vcl_numeric_limits<std::complex<double> > {
public:
typedef long std::complex<double> ValueType;
typedef long std::complex<double> PrintType;
...
};
If this was your solution, then if you send us your specialization code, we'll check it into
itk::NumericTraits
Jim
-----Original Message-----
From: insight-users-bounces+millerjv=crd.ge.com at itk.org
[mailto:insight-users-bounces+millerjv=crd.ge.com at itk.org]On Behalf Of
Suyash P. Awate
Sent: Monday, May 09, 2005 3:39 PM
To: insight-users at public.kitware.com
Subject: [Insight-users] numeric traits for the std::complex < >
Hello,
I needed to use a vector of std::complex<double> in ITK and had some
compilation errors, i.e.
---
no type named `RealType' in `class
itk::NumericTraits<std::complex<double> >'
---
I solved the problem by writing my own NumericTraits class for this
datatype and my program compiles now. However, I was wondering if this
was the right way to solve the problem. Also, was there something
already existing in ITK that I could was used to obtain a more elegant
solution ?
I would appreciate any help with this. Thanks.
Best regards,
Suyash.
_______________________________________________
Insight-users mailing list
Insight-users at itk.org
http://www.itk.org/mailman/listinfo/insight-users
More information about the Insight-users
mailing list