KWStyle - itkDefaultImageTraits.h
 
Matrix View
Description

1 /*=========================================================================
2
3   Program:   Insight Segmentation & Registration Toolkit
4   Module:    $RCSfile: itkDefaultImageTraits.h.html,v $
5   Language:  C++
6   Date:      $Date: 2006/01/17 19:15:34 $
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 __itkDefaultImageTraits_h
18 #define __itkDefaultImageTraits_h
19
20 #include "itkImageRegion.h"
21 #include "itkValarrayImageContainer.h"
22
23 namespace itk
24 {
25
26
27 /**
28  * Default ImageTraits for any PixelType.
29  *
30  * \sa Image
31  * \ingroup ImageObjects
32  */
33 template <typename TPixelType,
34           unsigned int VImageDimension,
35 LEN           typename TPixelContainer = ValarrayImageContainer<unsigned long, TPixelType> >
36 class DefaultImageTraits
37 MCM {
38 public:
39   /** The pixel type of the image. */
40   typedef TPixelType PixelType;
41
42   /** The dimension of the image. */
43   itkStaticConstMacro(ImageDimension, unsigned int, VImageDimension);
44   
45   /** The container of Pixels for the image. */
46   typedef TPixelContainer PixelContainer;
47
48   /** Index typedef support. An index is used to access pixel values. */
49   typedef Index<VImageDimension>  IndexType;
50
51   /** Offset typedef support. An offset is used to access pixel values. */
52   typedef Offset<VImageDimension>  OffsetType;
53
54   /** Size typedef support. A size is used to define region bounds. */
55   typedef Size<VImageDimension>  SizeType;
56
57 LEN   /** Region typedef support. A region is used to specify a subset of an image. */
58   typedef ImageRegion<VImageDimension>  RegionType;
59 };
60
61
62 // namespace itk
63
64 #endif
65

Generated by KWStyle 1.0b on Tuesday January,17 at 02:14:05PM
© Kitware Inc.