| 1 |
|
/*========================================================================= |
| 2 |
|
|
| 3 |
|
Program: Insight Segmentation & Registration Toolkit |
| 4 |
|
Module: $RCSfile: itkNumericTraitsRGBPixel.h.html,v $ |
| 5 |
|
Language: C++ |
| 6 |
|
Date: $Date: 2006/01/17 19:15:42 $ |
| 7 |
|
Version: $Revision: 1.4 $ |
| 8 |
|
|
| 9 |
|
Copyright (c) Insight Software Consortium. All rights reserved. |
| 10 |
|
See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details. |
| 11 |
|
|
| 12 |
|
This software is distributed WITHOUT ANY WARRANTY; without even |
| 13 |
|
the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR |
| 14 |
|
PURPOSE. See the above copyright notices for more information. |
| 15 |
|
|
| 16 |
|
=========================================================================*/ |
| 17 |
|
#ifndef __itkNumericTraitsRGBPixel_h |
| 18 |
|
#define __itkNumericTraitsRGBPixel_h |
| 19 |
|
|
| 20 |
|
#include "itkNumericTraits.h" |
| 21 |
|
#include "itkRGBPixel.h" |
| 22 |
|
|
| 23 |
|
namespace itk |
| 24 |
|
{ |
| 25 |
|
|
| 26 |
|
/** \class NumericTraits<RGBPixel<unsigned char> > |
| 27 |
|
* \brief Define traits for type RGBPixel<unsigned char>. |
| 28 |
|
* \ingroup DataRepresentation |
| 29 |
|
*/ |
| 30 |
|
template <> |
| 31 |
|
class NumericTraits<RGBPixel<unsigned char> > { |
| 32 |
|
public: |
| 33 |
|
typedef RGBPixel<unsigned char> ValueType; |
| 34 |
|
typedef RGBPixel<unsigned char> PrintType; |
| 35 |
|
typedef RGBPixel<unsigned char> AbsType; |
| 36 |
TDA |
typedef RGBPixel<unsigned short> AccumulateType; |
| 37 |
TDA |
typedef RGBPixel<double> RealType; |
| 38 |
TDA |
typedef double ScalarRealType; |
| 39 |
TDA |
typedef RGBPixel<float> FloatType; |
| 40 |
|
static const RGBPixel<unsigned char> ITKCommon_EXPORT Zero; |
| 41 |
|
static const RGBPixel<unsigned char> ITKCommon_EXPORT One; |
| 42 |
|
static ValueType ZeroValue() { return Zero; } |
| 43 |
|
|
| 44 |
|
}; |
| 45 |
|
|
| 46 |
|
} // end namespace itk |
| 47 |
|
|
| 48 |
|
#endif // __itkNumericTraitsRGBPixel_h |
| 49 |
|
|