SimpleITK  1.2.4
sitkLabelMapContourOverlayImageFilter.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 sitkLabelMapContourOverlayImageFilter_h
19 #define sitkLabelMapContourOverlayImageFilter_h
20 
21 /*
22  * WARNING: DO NOT EDIT THIS FILE!
23  * THIS FILE IS AUTOMATICALLY GENERATED BY THE SIMPLEITK BUILD PROCESS.
24  * Please look at sitkDualImageFilterTemplate.h.in to make changes.
25  */
26 
27 #include <memory>
28 
29 #include "sitkImageFilter.h"
31 #include "sitkBasicFilters.h"
32 
33 namespace itk {
34  namespace simple {
35 
54  public:
56 
59 
63 
66 
67 
68 
72  SITK_RETURN_SELF_TYPE_HEADER SetOpacity ( double Opacity ) { this->m_Opacity = Opacity; return *this; }
73 
77  double GetOpacity() const { return this->m_Opacity; }
78 
82  SITK_RETURN_SELF_TYPE_HEADER SetDilationRadius ( const std::vector<unsigned int> & DilationRadius ) { this->m_DilationRadius = DilationRadius; return *this; }
83 
85  SITK_RETURN_SELF_TYPE_HEADER SetDilationRadius( unsigned int value ) { this->m_DilationRadius = std::vector<unsigned int>(3, value); return *this; }
86 
87 
91  std::vector<unsigned int> GetDilationRadius() const { return this->m_DilationRadius; }
92 
96  SITK_RETURN_SELF_TYPE_HEADER SetContourThickness ( const std::vector<unsigned int> & ContourThickness ) { this->m_ContourThickness = ContourThickness; return *this; }
97 
101  std::vector<unsigned int> GetContourThickness() const { return this->m_ContourThickness; }
102 
106  SITK_RETURN_SELF_TYPE_HEADER SetSliceDimension ( unsigned int SliceDimension ) { this->m_SliceDimension = SliceDimension; return *this; }
107 
111  unsigned int GetSliceDimension() const { return this->m_SliceDimension; }
112 
113  typedef enum {PLAIN,CONTOUR,SLICE_CONTOUR} ContourTypeType;
114 
119  SITK_RETURN_SELF_TYPE_HEADER SetContourType ( ContourTypeType ContourType ) { this->m_ContourType = ContourType; return *this; }
120 
125  ContourTypeType GetContourType() const { return this->m_ContourType; }
126 
127  typedef enum {HIGH_LABEL_ON_TOP,LOW_LABEL_ON_TOP} PriorityType;
128 
132  SITK_RETURN_SELF_TYPE_HEADER SetPriority ( PriorityType Priority ) { this->m_Priority = Priority; return *this; }
133 
137  PriorityType GetPriority() const { return this->m_Priority; }
138 
141  SITK_RETURN_SELF_TYPE_HEADER SetColormap ( std::vector<uint8_t> Colormap ) { this->m_Colormap = Colormap; return *this; }
142 
145  std::vector<uint8_t> GetColormap() const { return this->m_Colormap; }
147  std::string GetName() const { return std::string ("LabelMapContourOverlayImageFilter"); }
148 
150  std::string ToString() const;
151 
152 
154  Image Execute ( const Image & labelMapImage, const Image & featureImage );
155 
156 
158  Image Execute ( const Image & labelMapImage, const Image & featureImage, double opacity, const std::vector<unsigned int> & dilationRadius, const std::vector<unsigned int> & contourThickness, unsigned int sliceDimension, LabelMapContourOverlayImageFilter::ContourTypeType contourType, LabelMapContourOverlayImageFilter::PriorityType priority, std::vector<uint8_t> colormap );
159 
160 
161  private:
163  typedef Image (Self::*MemberFunctionType)( const Image * labelMapImage, const Image * featureImage );
164 
165  friend struct detail::DualExecuteInternalAddressor<MemberFunctionType>;
166  template <class TImageType1, class TImageType2> Image DualExecuteInternal ( const Image * labelMapImage, const Image * featureImage );
167 
168 
169  nsstd::auto_ptr<detail::DualMemberFunctionFactory<MemberFunctionType> > m_DualMemberFactory;
170 
171 
172 
173  double m_Opacity;
174  std::vector<unsigned int> m_DilationRadius;
175  std::vector<unsigned int> m_ContourThickness;
176  unsigned int m_SliceDimension;
179  std::vector<uint8_t> m_Colormap;
180  };
181 
182 
183 
192  SITKBasicFilters_EXPORT Image LabelMapContourOverlay ( const Image & labelMapImage, const Image & featureImage, double opacity = 0.5, const std::vector<unsigned int> & dilationRadius = std::vector<unsigned int>(3, 1), const std::vector<unsigned int> & contourThickness = std::vector<unsigned int>(3, 1), unsigned int sliceDimension = 0u, LabelMapContourOverlayImageFilter::ContourTypeType contourType = itk::simple::LabelMapContourOverlayImageFilter::CONTOUR, LabelMapContourOverlayImageFilter::PriorityType priority = itk::simple::LabelMapContourOverlayImageFilter::HIGH_LABEL_ON_TOP, std::vector<uint8_t> colormap = std::vector<uint8_t>() );
193 
194  }
195 }
196 #endif
Apply a colormap to the contours (outlines) of each object in a label map and superimpose it on top o...
nsstd::auto_ptr< detail::DualMemberFunctionFactory< MemberFunctionType > > m_DualMemberFactory
#define SITKBasicFilters_EXPORT
typelist::MakeTypeList< LabelPixelID< uint8_t >, LabelPixelID< uint16_t >, LabelPixelID< uint32_t > >::Type LabelPixelIDTypeList
Image LabelMapContourOverlay(const Image &labelMapImage, const Image &featureImage, double opacity=0.5, const std::vector< unsigned int > &dilationRadius=std::vector< unsigned int >(3, 1), const std::vector< unsigned int > &contourThickness=std::vector< unsigned int >(3, 1), unsigned int sliceDimension=0u, LabelMapContourOverlayImageFilter::ContourTypeType contourType=itk::simple::LabelMapContourOverlayImageFilter::CONTOUR, LabelMapContourOverlayImageFilter::PriorityType priority=itk::simple::LabelMapContourOverlayImageFilter::HIGH_LABEL_ON_TOP, std::vector< uint8_t > colormap=std::vector< uint8_t >())
Apply a colormap to the contours (outlines) of each object in a label map and superimpose it on top o...
Self & SetContourThickness(const std::vector< unsigned int > &ContourThickness)
The Image class for SimpleITK.
Definition: sitkImage.h:78
Self & SetDilationRadius(const std::vector< unsigned int > &DilationRadius)
The base interface for SimpleITK filters that take one input image.