ITK  4.4.0
Insight Segmentation and Registration Toolkit
itkPolylineMask2DImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkPolylineMask2DImageFilter_h
19 #define __itkPolylineMask2DImageFilter_h
20 
21 #include "itkImageToImageFilter.h"
23 
24 namespace itk
25 {
47 template< class TInputImage, class TPolyline,
48  class TOutputImage >
49 class ITK_EXPORT PolylineMask2DImageFilter:public ImageToImageFilter< TInputImage, TOutputImage >
50 {
51 public:
57 
59  itkNewMacro(Self);
60 
63 
65  itkStaticConstMacro(NDimensions, unsigned int,
66  TInputImage::ImageDimension);
67  itkStaticConstMacro(NOutputDimensions, unsigned int,
68  TOutputImage::ImageDimension);
70 
72  typedef TInputImage InputImageType;
73  typedef typename InputImageType::ConstPointer InputImageConstPointer;
74  typedef typename InputImageType::Pointer InputImagePointer;
75  typedef typename InputImageType::RegionType InputImageRegionType;
76  typedef typename InputImageType::PixelType InputImagePixelType;
77 
78  /* typedef for the polyline type */
79  typedef TPolyline PolylineType;
80 
81  /* typedef for the output image */
82  typedef TOutputImage OutputImageType;
83  typedef typename OutputImageType::Pointer OutputImagePointer;
84  typedef typename OutputImageType::RegionType OutputImageRegionType;
85  typedef typename OutputImageType::PixelType OutputImagePixelType;
86 
88  void SetInput1(const InputImageType *image);
89 
90  void SetInput2(const PolylineType *polyline);
91 
92  /* Generate Data */
93  void GenerateData(void);
94 
95 #ifdef ITK_USE_CONCEPT_CHECKING
96 
97  itkConceptMacro( SameDimensionCheck,
99  itkConceptMacro( IntConvertibleOutputCheck,
101  itkConceptMacro( OutputEqualityComparableCheck,
103  itkConceptMacro( InputConvertibleToOutputCheck,
105 
107 #endif
108 
109 protected:
112 
113 private:
114  PolylineMask2DImageFilter(const Self &); //purposely not implemented
115  void operator=(const Self &); //purposely not implemented
116 };
117 } // end namespace itk
118 
119 #ifndef ITK_MANUAL_INSTANTIATION
120 #include "itkPolylineMask2DImageFilter.hxx"
121 #endif
122 
123 #endif
124