VTK
vtkImageAccumulate.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageAccumulate.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 =========================================================================*/
37 #ifndef vtkImageAccumulate_h
38 #define vtkImageAccumulate_h
39 
40 #include "vtkImagingStatisticsModule.h" // For export macro
41 #include "vtkImageAlgorithm.h"
42 
44 
45 class VTKIMAGINGSTATISTICS_EXPORT vtkImageAccumulate : public vtkImageAlgorithm
46 {
47 public:
48  static vtkImageAccumulate *New();
50  void PrintSelf(ostream& os, vtkIndent indent) override;
51 
53 
62  vtkSetVector3Macro(ComponentSpacing, double);
63  vtkGetVector3Macro(ComponentSpacing, double);
65 
67 
76  vtkSetVector3Macro(ComponentOrigin, double);
77  vtkGetVector3Macro(ComponentOrigin, double);
79 
81 
89  void SetComponentExtent(int extent[6]);
90  void SetComponentExtent(int minX, int maxX, int minY, int maxY,
91  int minZ, int maxZ);
92  void GetComponentExtent(int extent[6]);
93  int *GetComponentExtent() VTK_SIZEHINT(6) {return this->ComponentExtent;}
95 
96 
98 
104  void SetStencilData(vtkImageStencilData *stencil);
105  vtkImageStencilData *GetStencil();
107 
109 
112  vtkSetClampMacro(ReverseStencil, vtkTypeBool, 0, 1);
113  vtkBooleanMacro(ReverseStencil, vtkTypeBool);
114  vtkGetMacro(ReverseStencil, vtkTypeBool);
116 
118 
123  vtkGetVector3Macro(Min, double);
124  vtkGetVector3Macro(Max, double);
125  vtkGetVector3Macro(Mean, double);
126  vtkGetVector3Macro(StandardDeviation, double);
127  vtkGetMacro(VoxelCount, vtkIdType);
129 
131 
134  vtkSetClampMacro(IgnoreZero, vtkTypeBool, 0, 1);
135  vtkGetMacro(IgnoreZero, vtkTypeBool);
136  vtkBooleanMacro(IgnoreZero, vtkTypeBool);
138 
139 protected:
141  ~vtkImageAccumulate() override;
142 
143  double ComponentSpacing[3];
144  double ComponentOrigin[3];
145  int ComponentExtent[6];
146 
149  vtkInformationVector*) override;
152  vtkInformationVector*) override;
153  int RequestData(vtkInformation* request,
154  vtkInformationVector** inputVector,
155  vtkInformationVector* outputVector) override;
156 
158  double Min[3];
159  double Max[3];
160  double Mean[3];
161  double StandardDeviation[3];
163 
165 
166  int FillInputPortInformation(int port, vtkInformation* info) override;
167 
168 private:
169  vtkImageAccumulate(const vtkImageAccumulate&) = delete;
170  void operator=(const vtkImageAccumulate&) = delete;
171 };
172 
173 #endif
174 
175 
176 
Store vtkAlgorithm input/output information.
int vtkIdType
Definition: vtkType.h:347
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
Subclasses can reimplement this method to translate the update extent requests from each output port ...
int vtkTypeBool
Definition: vtkABI.h:69
a simple class to control print indentation
Definition: vtkIndent.h:33
efficient description of an image stencil
virtual int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
Subclasses can reimplement this method to collect information from their inputs and set information f...
#define VTK_SIZEHINT(...)
Generalized histograms up to 3 dimensions.
int FillInputPortInformation(int port, vtkInformation *info) override
These method should be reimplemented by subclasses that have more than a single input or single outpu...
Generic algorithm superclass for image algs.
Store zero or more vtkInformation instances.
static vtkAlgorithm * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called in response to a REQUEST_DATA request from the executive.
int * GetComponentExtent()
Set/Get - The component extent sets the number/extent of the bins.