VTK  9.0.20210424
vtkImageStencilToImage.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageStencilToImage.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
28 #ifndef vtkImageStencilToImage_h
29 #define vtkImageStencilToImage_h
30 
31 #include "vtkImageAlgorithm.h"
32 #include "vtkImagingStencilModule.h" // For export macro
33 
34 class VTKIMAGINGSTENCIL_EXPORT vtkImageStencilToImage : public vtkImageAlgorithm
35 {
36 public:
39  void PrintSelf(ostream& os, vtkIndent indent) override;
40 
42 
45  vtkSetMacro(OutsideValue, double);
46  vtkGetMacro(OutsideValue, double);
48 
50 
53  vtkSetMacro(InsideValue, double);
54  vtkGetMacro(InsideValue, double);
56 
58 
61  vtkSetMacro(OutputScalarType, int);
62  vtkGetMacro(OutputScalarType, int);
63  void SetOutputScalarTypeToFloat() { this->SetOutputScalarType(VTK_FLOAT); }
64  void SetOutputScalarTypeToDouble() { this->SetOutputScalarType(VTK_DOUBLE); }
65  void SetOutputScalarTypeToInt() { this->SetOutputScalarType(VTK_INT); }
66  void SetOutputScalarTypeToUnsignedInt() { this->SetOutputScalarType(VTK_UNSIGNED_INT); }
67  void SetOutputScalarTypeToLong() { this->SetOutputScalarType(VTK_LONG); }
68  void SetOutputScalarTypeToUnsignedLong() { this->SetOutputScalarType(VTK_UNSIGNED_LONG); }
69  void SetOutputScalarTypeToShort() { this->SetOutputScalarType(VTK_SHORT); }
70  void SetOutputScalarTypeToUnsignedShort() { this->SetOutputScalarType(VTK_UNSIGNED_SHORT); }
71  void SetOutputScalarTypeToUnsignedChar() { this->SetOutputScalarType(VTK_UNSIGNED_CHAR); }
72  void SetOutputScalarTypeToChar() { this->SetOutputScalarType(VTK_CHAR); }
74 
75 protected:
78 
80 
82 
83  double OutsideValue;
84  double InsideValue;
86 
88 
89 private:
91  void operator=(const vtkImageStencilToImage&) = delete;
92 };
93 
94 #endif
vtkImageStencilToImage::SetOutputScalarTypeToUnsignedShort
void SetOutputScalarTypeToUnsignedShort()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:70
vtkImageStencilToImage::SetOutputScalarTypeToInt
void SetOutputScalarTypeToInt()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:65
vtkImageStencilToImage::RequestData
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called in response to a REQUEST_DATA request from the executive.
VTK_UNSIGNED_INT
#define VTK_UNSIGNED_INT
Definition: vtkType.h:51
vtkImageStencilToImage::OutputScalarType
int OutputScalarType
Definition: vtkImageStencilToImage.h:85
vtkImageStencilToImage::SetOutputScalarTypeToDouble
void SetOutputScalarTypeToDouble()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:64
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:36
VTK_UNSIGNED_SHORT
#define VTK_UNSIGNED_SHORT
Definition: vtkType.h:49
vtkImageStencilToImage::FillInputPortInformation
int FillInputPortInformation(int, vtkInformation *) override
These method should be reimplemented by subclasses that have more than a single input or single outpu...
vtkImageAlgorithm.h
vtkImageStencilToImage::~vtkImageStencilToImage
~vtkImageStencilToImage() override
vtkImageStencilToImage::SetOutputScalarTypeToUnsignedLong
void SetOutputScalarTypeToUnsignedLong()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:68
vtkImageStencilToImage::SetOutputScalarTypeToLong
void SetOutputScalarTypeToLong()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:67
vtkImageAlgorithm
Generic algorithm superclass for image algs.
Definition: vtkImageAlgorithm.h:38
vtkImageStencilToImage::RequestInformation
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
Subclasses can reimplement this method to collect information from their inputs and set information f...
vtkImageStencilToImage::SetOutputScalarTypeToUnsignedChar
void SetOutputScalarTypeToUnsignedChar()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:71
vtkImageStencilToImage::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkImageStencilToImage::InsideValue
double InsideValue
Definition: vtkImageStencilToImage.h:84
vtkImageStencilToImage::SetOutputScalarTypeToFloat
void SetOutputScalarTypeToFloat()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:63
vtkImageStencilToImage::OutsideValue
double OutsideValue
Definition: vtkImageStencilToImage.h:83
VTK_CHAR
#define VTK_CHAR
Definition: vtkType.h:45
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:34
VTK_FLOAT
#define VTK_FLOAT
Definition: vtkType.h:54
vtkImageStencilToImage::New
static vtkImageStencilToImage * New()
VTK_DOUBLE
#define VTK_DOUBLE
Definition: vtkType.h:55
VTK_UNSIGNED_CHAR
#define VTK_UNSIGNED_CHAR
Definition: vtkType.h:47
VTK_LONG
#define VTK_LONG
Definition: vtkType.h:52
vtkImageStencilToImage::SetOutputScalarTypeToUnsignedInt
void SetOutputScalarTypeToUnsignedInt()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:66
VTK_UNSIGNED_LONG
#define VTK_UNSIGNED_LONG
Definition: vtkType.h:53
vtkImageStencilToImage::SetOutputScalarTypeToChar
void SetOutputScalarTypeToChar()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:72
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:74
vtkImageStencilToImage::vtkImageStencilToImage
vtkImageStencilToImage()
VTK_SHORT
#define VTK_SHORT
Definition: vtkType.h:48
vtkImageStencilToImage::SetOutputScalarTypeToShort
void SetOutputScalarTypeToShort()
The desired output scalar type.
Definition: vtkImageStencilToImage.h:69
vtkImageStencilToImage
Convert an image stencil into an image.
Definition: vtkImageStencilToImage.h:35
VTK_INT
#define VTK_INT
Definition: vtkType.h:50