SimpleITK  1.2.4
sitkLabelMapOverlayImageFilter.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 sitkLabelMapOverlayImageFilter_h
19 #define sitkLabelMapOverlayImageFilter_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 
58  virtual ~LabelMapOverlayImageFilter();
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 
81  SITK_RETURN_SELF_TYPE_HEADER SetColormap ( std::vector<unsigned char> Colormap ) { this->m_Colormap = Colormap; return *this; }
82 
85  std::vector<unsigned char> GetColormap() const { return this->m_Colormap; }
87  std::string GetName() const { return std::string ("LabelMapOverlayImageFilter"); }
88 
90  std::string ToString() const;
91 
92 
94  Image Execute ( const Image & labelMapImage, const Image & featureImage );
95 
96 
98  Image Execute ( const Image & labelMapImage, const Image & featureImage, double opacity, std::vector<unsigned char> colormap );
99 
100 
101  private:
103  typedef Image (Self::*MemberFunctionType)( const Image * labelMapImage, const Image * featureImage );
104 
105  friend struct detail::DualExecuteInternalAddressor<MemberFunctionType>;
106  template <class TImageType1, class TImageType2> Image DualExecuteInternal ( const Image * labelMapImage, const Image * featureImage );
107 
108 
109  nsstd::auto_ptr<detail::DualMemberFunctionFactory<MemberFunctionType> > m_DualMemberFactory;
110 
111 
112 
113  /* Value assigned to pixels outside of the mask */
114  double m_Opacity;
115  std::vector<unsigned char> m_Colormap;
116  };
117 
118 
119 
128  SITKBasicFilters_EXPORT Image LabelMapOverlay ( const Image & labelMapImage, const Image & featureImage, double opacity = 0.5, std::vector<unsigned char> colormap = std::vector<unsigned char>() );
129 
130  }
131 }
132 #endif
Apply a colormap to a label map and superimpose it on an image.
std::vector< unsigned char > GetColormap() const
#define SITKBasicFilters_EXPORT
typelist::MakeTypeList< LabelPixelID< uint8_t >, LabelPixelID< uint16_t >, LabelPixelID< uint32_t > >::Type LabelPixelIDTypeList
The Image class for SimpleITK.
Definition: sitkImage.h:78
Image LabelMapOverlay(const Image &labelMapImage, const Image &featureImage, double opacity=0.5, std::vector< unsigned char > colormap=std::vector< unsigned char >())
Apply a colormap to a label map and superimpose it on an image.
nsstd::auto_ptr< detail::DualMemberFunctionFactory< MemberFunctionType > > m_DualMemberFactory
The base interface for SimpleITK filters that take one input image.
Self & SetColormap(std::vector< unsigned char > Colormap)