VTK  9.1.0
vtkImageShrink3D.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkImageShrink3D.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=========================================================================*/
32#ifndef vtkImageShrink3D_h
33#define vtkImageShrink3D_h
34
35#include "vtkImagingCoreModule.h" // For export macro
37
38class VTKIMAGINGCORE_EXPORT vtkImageShrink3D : public vtkThreadedImageAlgorithm
39{
40public:
43 void PrintSelf(ostream& os, vtkIndent indent) override;
44
46
49 vtkSetVector3Macro(ShrinkFactors, int);
50 vtkGetVector3Macro(ShrinkFactors, int);
52
54
57 vtkSetVector3Macro(Shift, int);
58 vtkGetVector3Macro(Shift, int);
60
62
70 vtkTypeBool GetAveraging() { return this->GetMean(); }
71 vtkBooleanMacro(Averaging, vtkTypeBool);
73
75 vtkGetMacro(Mean, vtkTypeBool);
76 vtkBooleanMacro(Mean, vtkTypeBool);
77
79 vtkGetMacro(Minimum, vtkTypeBool);
80 vtkBooleanMacro(Minimum, vtkTypeBool);
81
83 vtkGetMacro(Maximum, vtkTypeBool);
84 vtkBooleanMacro(Maximum, vtkTypeBool);
85
87 vtkGetMacro(Median, vtkTypeBool);
88 vtkBooleanMacro(Median, vtkTypeBool);
89
90protected:
92 ~vtkImageShrink3D() override = default;
93
94 int ShrinkFactors[3];
95 int Shift[3];
96 int Mean;
100
103
105 vtkInformationVector* outputVector, vtkImageData*** inData, vtkImageData** outData, int ext[6],
106 int id) override;
107
108 void InternalRequestUpdateExtent(int* inExt, int* outExt);
109
110private:
111 vtkImageShrink3D(const vtkImageShrink3D&) = delete;
112 void operator=(const vtkImageShrink3D&) = delete;
113};
114
115#endif
topologically and geometrically regular array of data
Definition: vtkImageData.h:57
Subsamples an image.
vtkTypeBool Minimum
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTypeBool Maximum
void SetAveraging(vtkTypeBool)
Choose Mean, Minimum, Maximum, Median or sub sampling.
void SetMean(vtkTypeBool)
vtkTypeBool Median
void SetMinimum(vtkTypeBool)
~vtkImageShrink3D() override=default
static vtkImageShrink3D * New()
vtkTypeBool GetAveraging()
Choose Mean, Minimum, Maximum, Median or sub sampling.
void ThreadedRequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inData, vtkImageData **outData, int ext[6], int id) override
If the subclass does not define an Execute method, then the task will be broken up,...
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
Subclasses can reimplement this method to collect information from their inputs and set information f...
void SetMedian(vtkTypeBool)
int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
Subclasses can reimplement this method to translate the update extent requests from each output port ...
void SetMaximum(vtkTypeBool)
void InternalRequestUpdateExtent(int *inExt, int *outExt)
a simple class to control print indentation
Definition: vtkIndent.h:43
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Generic filter that has one input.
int vtkTypeBool
Definition: vtkABI.h:69