VTK  9.7.1
vtkTemporalSmoothing.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
14 #ifndef vtkTemporalSmoothing_h
15 #define vtkTemporalSmoothing_h
16 
17 #include "vtkFiltersTemporalModule.h" // For export macro
19 
20 #include <memory> // For smart pointers
21 
22 VTK_ABI_NAMESPACE_BEGIN
23 struct vtkTemporalSmoothingInternals;
25 class vtkFieldData;
26 class vtkDataSet;
28 class vtkInformation;
29 class vtkGraph;
30 
31 class VTKFILTERSTEMPORAL_EXPORT vtkTemporalSmoothing : public vtkPassInputTypeAlgorithm
32 {
33 public:
35 
38  static vtkTemporalSmoothing* New();
40  void PrintSelf(ostream& os, vtkIndent indent) override;
42 
44 
49  vtkGetMacro(TemporalWindowHalfWidth, int);
50  vtkSetMacro(TemporalWindowHalfWidth, int);
52 
53 protected:
55  ~vtkTemporalSmoothing() override = default;
56 
57  int RequestDataObject(vtkInformation* request, vtkInformationVector** inputVector,
58  vtkInformationVector* outputVector) override;
59  int RequestInformation(vtkInformation* request, vtkInformationVector** inputVector,
60  vtkInformationVector* outputVector) override;
61  int RequestUpdateExtent(vtkInformation* request, vtkInformationVector** inputVector,
62  vtkInformationVector* outputVector) override;
63  int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
64  vtkInformationVector* outputVector) override;
65 
66 private:
68  void operator=(const vtkTemporalSmoothing&) = delete;
69 
70  void Initialize(vtkDataObject* input, vtkDataObject* output, vtkDataObject* cache);
71  void Initialize(vtkDataSet* input, vtkDataSet* output, vtkDataSet* cache);
72  void Initialize(vtkGraph* input, vtkGraph* output, vtkGraph* cache);
73  void Initialize(
75  void InitializeArrays(vtkFieldData* inFd, vtkFieldData* outFd);
76  void InitializeArray(vtkDataArray* array, vtkFieldData* outFd);
77 
78  void AccumulateSum(vtkDataObject* input, vtkDataObject* output);
79  void AccumulateSum(vtkDataSet* input, vtkDataSet* output);
80  void AccumulateSum(vtkGraph* input, vtkGraph* output);
81  void AccumulateSum(vtkCompositeDataSet* input, vtkCompositeDataSet* output);
82  void AccumulateArrays(vtkFieldData* inFd, vtkFieldData* outFd);
83 
84  void PostExecute(vtkDataObject* input, vtkDataObject* output);
85  void PostExecute(vtkDataSet* input, vtkDataSet* output);
86  void PostExecute(vtkGraph* input, vtkGraph* output);
87  void PostExecute(vtkCompositeDataSet* input, vtkCompositeDataSet* output);
88  void FinishArrays(vtkFieldData* inFd, vtkFieldData* outFd);
89 
90  int TemporalWindowHalfWidth = 10;
91  std::shared_ptr<vtkTemporalSmoothingInternals> Internals;
92 };
93 
94 VTK_ABI_NAMESPACE_END
95 #endif
virtual int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks for Information.
Superclass for algorithms that produce output of the same type as input.
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:56
Base class for graph data types.
Definition: vtkGraph.h:282
Smooth point or cell data over a sliding time window.
abstract superclass for composite (multi-block or AMR) datasets
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when each filter in the pipeline decides what portion of its inp...
a simple class to control print indentation
Definition: vtkIndent.h:28
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:44
virtual int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called within ProcessRequest when a request asks the algorithm to create empty output data ob...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Store zero or more vtkInformation instances.
general representation of visualization data
Definition: vtkDataObject.h:55
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called within ProcessRequest when a request asks the algorithm to do its work.
static vtkPassInputTypeAlgorithm * New()
Represents and manipulates a collection of data arrays.
Definition: vtkFieldData.h:51