MantisBT - ITK | |||||
| View Issue Details | |||||
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0005006 | ITK | public | 2007-05-09 18:30 | 2007-09-17 12:09 | |
| Reporter | Dan Mueller | ||||
| Assigned To | Luis Ibanez | ||||
| Priority | low | Severity | major | Reproducibility | always |
| Status | closed | Resolution | fixed | ||
| Platform | OS | OS Version | |||
| Product Version | |||||
| Target Version | Fixed in Version | ||||
| Resolution Date | |||||
| Sprint | |||||
| Sprint Status | |||||
| Summary | 0005006: Incorrect NumericTraits for RGBPixel | ||||
| Description | In Code/Common/itkNumericTraitsRGBPixel.h the ValueType, PrintType, and AbsType for unsigned short is incorrect (it has unsigned char, not unsigned short). It currently reads: /** \class NumericTraits<RGBPixel<unsigned short> > * \brief Define traits for type RGBPixel<unsigned char>. * \ingroup DataRepresentation */ template <> class NumericTraits<RGBPixel<unsigned short> > { public: typedef RGBPixel<unsigned char> ValueType; //<< typedef RGBPixel<unsigned char> PrintType; //<< typedef RGBPixel<unsigned char> AbsType; //<< typedef RGBPixel<unsigned short> AccumulateType; typedef RGBPixel<double> RealType; typedef double ScalarRealType; typedef RGBPixel<float> FloatType; static const RGBPixel<unsigned short> ITKCommon_EXPORT Zero; static const RGBPixel<unsigned short> ITKCommon_EXPORT One; static ValueType ZeroValue() { return Zero; } }; but should read: /** \class NumericTraits<RGBPixel<unsigned short> > * \brief Define traits for type RGBPixel<unsigned short>. * \ingroup DataRepresentation */ template <> class NumericTraits<RGBPixel<unsigned short> > { public: typedef RGBPixel<unsigned short> ValueType; //<< typedef RGBPixel<unsigned short> PrintType; //<< typedef RGBPixel<unsigned short> AbsType; //<< typedef RGBPixel<unsigned short> AccumulateType; typedef RGBPixel<double> RealType; typedef double ScalarRealType; typedef RGBPixel<float> FloatType; static const RGBPixel<unsigned short> ITKCommon_EXPORT Zero; static const RGBPixel<unsigned short> ITKCommon_EXPORT One; static ValueType ZeroValue() { return Zero; } }; The comment is also wrong (has char instead of short). I have attached a file with the correction. | ||||
| Steps To Reproduce | |||||
| Additional Information | |||||
| Tags | No tags attached. | ||||
| Relationships | |||||
| Attached Files | https://public.kitware.com/Bug/file/998/itkNumericTraitsRGBPixel.h | ||||
| Issue History | |||||
| Date Modified | Username | Field | Change | ||
| 2007-09-17 09:07 | Luis Ibanez | Note Added: 0009013 | |||
| 2007-09-17 09:07 | Luis Ibanez | Status | assigned => acknowledged | ||
| 2007-09-17 09:12 | Luis Ibanez | Note Added: 0009014 | |||
| 2007-09-17 12:09 | Luis Ibanez | Status | acknowledged => closed | ||
| 2007-09-17 12:09 | Luis Ibanez | Note Added: 0009026 | |||
| 2007-09-17 12:09 | Luis Ibanez | Resolution | open => fixed | ||
| Notes | |||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||