#include <itkDefaultConvertPixelTraits.h>
TOutputPixelType is the destination type. The input type is infered by the templated static function Convert.
This implementaion, does a simple assignment operator, so if you are going from from a higher bit representation to a lower bit one (int to char), you may want to specialize and add some sort of transfer function.
Definition at line 40 of file itkDefaultConvertPixelTraits.h.
Public Types | |
| typedef PixelType::ComponentType | ComponentType |
Static Public Member Functions | |
| static ComponentType | GetNthComponent (int c, const PixelType &pixel) |
| static unsigned int | GetNumberOfComponents () |
| static ComponentType | GetScalarValue (const PixelType &pixel) |
| static void | SetNthComponent (int c, PixelType &pixel, const ComponentType &v) |
| typedef PixelType::ComponentType itk::DefaultConvertPixelTraits< PixelType >::ComponentType |
Determine the pixel data type.
Definition at line 44 of file itkDefaultConvertPixelTraits.h.
| static ComponentType itk::DefaultConvertPixelTraits< PixelType >::GetNthComponent | ( | int | c, | |
| const PixelType & | pixel | |||
| ) | [inline, static] |
Return the nth component of the pixel.
Definition at line 51 of file itkDefaultConvertPixelTraits.h.
| static unsigned int itk::DefaultConvertPixelTraits< PixelType >::GetNumberOfComponents | ( | ) | [inline, static] |
Return the number of components per pixel.
Definition at line 47 of file itkDefaultConvertPixelTraits.h.
| static ComponentType itk::DefaultConvertPixelTraits< PixelType >::GetScalarValue | ( | const PixelType & | pixel | ) | [inline, static] |
Return a single scalar value from this pixel.
Definition at line 59 of file itkDefaultConvertPixelTraits.h.
| static void itk::DefaultConvertPixelTraits< PixelType >::SetNthComponent | ( | int | c, | |
| PixelType & | pixel, | |||
| const ComponentType & | v | |||
| ) | [inline, static] |
Set the nth component of the pixel.
Definition at line 55 of file itkDefaultConvertPixelTraits.h.
1.5.5 written by Dimitri van Heesch,
© 1997-2000