SimpleITK  
sitkLabelMapMaskImageFilter.h
Go to the documentation of this file.
1/*=========================================================================
2*
3* Copyright NumFOCUS
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 sitkLabelMapMaskImageFilter_h
19#define sitkLabelMapMaskImageFilter_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.jinja to make changes.
25 */
26
27#include <memory>
28
29#include "sitkImageFilter.h"
31#include "sitkBasicFilters.h"
33
34namespace itk::simple {
35
55public:
57
60
64
67
68
69
70
74 void
75 SetLabel(uint64_t Label )
76 { this->m_Label = Label; }
77
80 uint64_t
81 GetLabel() const { return this->m_Label; }
82
83
87 void
88 SetBackgroundValue(double BackgroundValue )
89 { this->m_BackgroundValue = BackgroundValue; }
90
93 double
94 GetBackgroundValue() const { return this->m_BackgroundValue; }
95
96
100 void
101 SetNegated(bool Negated )
102 { this->m_Negated = Negated; }
103
105 void
106 NegatedOn() { return this->SetNegated(true); }
107 void
108 NegatedOff() { return this->SetNegated(false); }
112 bool
113 GetNegated() const { return this->m_Negated; }
114
115
119 void
121 { this->m_Crop = Crop; }
122
124 void
125 CropOn() { return this->SetCrop(true); }
126 void
127 CropOff() { return this->SetCrop(false); }
131 bool
132 GetCrop() const { return this->m_Crop; }
133
134
138 void
139 SetCropBorder(std::vector<unsigned int> CropBorder )
140 { this->m_CropBorder = std::move(CropBorder); }
141
143 void
144 SetCropBorder( unsigned int value ) { this->m_CropBorder = std::vector<unsigned int>(3, value); }
148 std::vector<unsigned int>
149 GetCropBorder() const { return this->m_CropBorder; }
150
151
153 std::string GetName() const { return std::string("LabelMapMaskImageFilter"); }
154
156 std::string ToString() const;
157
158
160 Image Execute(const Image &labelMapImage, const Image &featureImage);
161
162private:
163
165 using MemberFunctionType = Image (Self::*)(const Image *
166 labelMapImage, const Image *
167 featureImage);
168
170 template <class TImageType1, class TImageType2> Image DualExecuteInternal(const Image *
171 labelMapImage, const Image *
172 featureImage);
173
174
176
177
178
179 uint64_t m_Label{ 1u };
180
181 double m_BackgroundValue{ 0 };
182
183 bool m_Negated{ false };
184
185 bool m_Crop{ false };
186
187 std::vector<unsigned int> m_CropBorder{ std::vector<unsigned int>(3, 0) };
188
189
190
191
192
193
194
195};
196
197
207 const Image &labelMapImage, const Image &featureImage, uint64_t label = 1u, double backgroundValue = 0, bool negated = false, bool crop = false, std::vector<unsigned int> cropBorder = std::vector<unsigned int>(3, 0)
208);
209
211
212}
213#endif
The Image class for SimpleITK.
Definition sitkImage.h:77
std::vector< unsigned int > GetCropBorder() const
void SetCropBorder(std::vector< unsigned int > CropBorder)
Image Execute(const Image &labelMapImage, const Image &featureImage)
Image(Self::*)(const Image * labelMapImage, const Image * featureImage) MemberFunctionType
Image DualExecuteInternal(const Image *labelMapImage, const Image *featureImage)
static const detail::DualMemberFunctionFactory< MemberFunctionType > & GetMemberFunctionFactory()
A class used to instantiate and generate function objects of templated member functions with two temp...
Image Crop(Image &&image1, std::vector< unsigned int > lowerBoundaryCropSize=std::vector< unsigned int >(3, 0), std::vector< unsigned int > upperBoundaryCropSize=std::vector< unsigned int >(3, 0))
Decrease the image size by cropping the image by an itk::Size at both the upper and lower bounds of t...
typelist2::typelist< LabelPixelID< uint8_t >, LabelPixelID< uint16_t >, LabelPixelID< uint32_t > > LabelPixelIDTypeList
Image LabelMapMask(const Image &labelMapImage, const Image &featureImage, uint64_t label=1u, double backgroundValue=0, bool negated=false, bool crop=false, std::vector< unsigned int > cropBorder=std::vector< unsigned int >(3, 0))
Mask and image with a LabelMap .
#define SITKBasicFilters_EXPORT