VTK  9.2.6
vtkAppendFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkAppendFilter.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 =========================================================================*/
39 #ifndef vtkAppendFilter_h
40 #define vtkAppendFilter_h
41 
42 #include "vtkFiltersCoreModule.h" // For export macro
44 
47 
48 class VTKFILTERSCORE_EXPORT vtkAppendFilter : public vtkUnstructuredGridAlgorithm
49 {
50 public:
51  static vtkAppendFilter* New();
53  void PrintSelf(ostream& os, vtkIndent indent) override;
54 
56 
59  vtkDataSet* GetInput(int idx);
60  vtkDataSet* GetInput() { return this->GetInput(0); }
62 
64 
69  vtkGetMacro(MergePoints, vtkTypeBool);
70  vtkSetMacro(MergePoints, vtkTypeBool);
71  vtkBooleanMacro(MergePoints, vtkTypeBool);
73 
75 
82  vtkSetClampMacro(Tolerance, double, 0.0, VTK_DOUBLE_MAX);
83  vtkGetMacro(Tolerance, double);
85 
87 
92  vtkSetMacro(ToleranceIsAbsolute, bool);
93  vtkGetMacro(ToleranceIsAbsolute, bool);
94  vtkBooleanMacro(ToleranceIsAbsolute, bool);
96 
100  void RemoveInputData(vtkDataSet* in);
101 
106  vtkDataSetCollection* GetInputList();
107 
109 
114  vtkSetClampMacro(OutputPointsPrecision, int, SINGLE_PRECISION, DEFAULT_PRECISION);
115  vtkGetMacro(OutputPointsPrecision, int);
117 
118 protected:
119  vtkAppendFilter();
120  ~vtkAppendFilter() override;
121 
122  // Usual data generation method
125  int FillInputPortInformation(int port, vtkInformation* info) override;
126 
127  // list of data sets to append together.
128  // Here as a convenience. It is a copy of the input array.
130 
131  // If true we will attempt to merge points. Must also not have
132  // ghost cells defined.
134 
136  double Tolerance;
137 
138  // If true, tolerance is used as is. If false, tolerance is multiplied by
139  // the diagonal of the bounding box of the input.
141 
142 private:
143  vtkAppendFilter(const vtkAppendFilter&) = delete;
144  void operator=(const vtkAppendFilter&) = delete;
145 
146  // Get all input data sets that have points, cells, or both.
147  // Caller must delete the returned vtkDataSetCollection.
148  vtkDataSetCollection* GetNonEmptyInputs(vtkInformationVector** inputVector);
149 
150  void AppendArrays(int attributesType, vtkInformationVector** inputVector, vtkIdType* globalIds,
151  vtkUnstructuredGrid* output, vtkIdType totalNumberOfElements);
152 };
153 
154 #endif
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
maintain an unordered list of dataset objects
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165
Store vtkAlgorithm input/output information.
abstract class to specify dataset behavior
Definition: vtkDataSet.h:62
static vtkUnstructuredGridAlgorithm * New()
vtkDataSet * GetInput()
Get any input of this filter.
int vtkIdType
Definition: vtkType.h:332
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
int vtkTypeBool
Definition: vtkABI.h:69
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
a simple class to control print indentation
Definition: vtkIndent.h:39
dataset represents arbitrary combinations of all possible cell types
vtkDataSetCollection * InputList
represent and manipulate attribute data in a dataset
Superclass for algorithms that produce only unstructured grid as output.
appends one or more datasets together into a single unstructured grid
vtkTypeBool MergePoints
Store zero or more vtkInformation instances.
virtual int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
This is called by the superclass.