13 #ifndef mitkPixelTypeTraits_h
14 #define mitkPixelTypeTraits_h
16 #include <itkDiffusionTensor3D.h>
18 #include <itkImageIOBase.h>
19 #include <itkRGBAPixel.h>
20 #include <itkRGBPixel.h>
21 #include <itkVectorImage.h>
33 template <
typename TValueType>
37 #define MITK_PIXEL_COMPONENT_TYPE(type, ctype, name) \
39 struct mitk::MapPixelComponentType<type> \
41 static const int value = ctype; \
43 std::string mitk::PixelComponentTypeToString() \
50 static const int PixelUserType =
static_cast<int>(itk::IOPixelEnum::MATRIX) + 1;
61 static const itk::IOComponentEnum
value = itk::ImageIOBase::MapPixelType<T>::CType;
71 static const bool value =
false;
75 #define DEFINE_TYPE_PRIMITIVE(_TYPEIN) \
77 struct isPrimitiveType<_TYPEIN> \
79 static const bool value = true; \
105 template <
typename TPixelType,
unsigned int VDimension = 0>
112 template <
typename TPixelType,
unsigned int VDimension>
115 typedef itk::VectorImage<TPixelType, VDimension>
ImageType;
119 template <
typename T>
126 template <
typename TPixelType,
unsigned int VDimension>
129 typedef itk::VectorImage<TPixelType, VDimension>
ImageType;
134 template <
bool flag,
typename T>
144 template <
typename T>
151 template <
typename T>
161 template <
bool V,
typename T>
168 template <
typename T>
171 static const size_t Size = T::ValueType::Length;
222 template <
class C,
unsigned int N>
228 template <
class C,
unsigned int N>
234 template <
class C,
unsigned int N>
240 template <
class C,
unsigned int N>
255 template <
class T,
bool Primitive>
#define DEFINE_TYPE_PRIMITIVE(_TYPEIN)
Provides a partial specialization for the.
Find image slices visible on a given plane.
itk::IOPixelEnum itkIOPixelType
static const int PixelUserType
static const int PixelComponentUserType
itk::IOComponentEnum itkIOComponentType
Object for compile-time resolving of the number of components for given type.
Compile time resolving of the type of a component.
PixelTypeTrait< isPrimitiveType< T >::value, T >::ValueType ComponentType
itk::VectorImage< TPixelType, VDimension > ImageType
itk::VectorImage< TPixelType, VDimension > ImageType
itk::Image< TPixelType, VDimension > ImageType
static const bool IsVectorImage
Object for compile-time translation of a composite pixel type into an itk::ImageIOBase::IOPixelType i...
static const itkIOPixelType IOCompositeType
static const itk::IOComponentEnum value
Object for compile-time translation of a pixel type into an itk::ImageIOBase::IOPixelType information...
static const itkIOComponentType IOComponentType
static const itkIOPixelType IOPixelType
Compile-time trait for resolving the ValueType from an ItkImageType.
This is an implementation of a type trait to provide a compile-time check for PixelType used in the i...