VTK  9.1.0
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=========================================================================*/
36#ifndef vtkAppendFilter_h
37#define vtkAppendFilter_h
38
39#include "vtkFiltersCoreModule.h" // For export macro
41
44
45class VTKFILTERSCORE_EXPORT vtkAppendFilter : public vtkUnstructuredGridAlgorithm
46{
47public:
50 void PrintSelf(ostream& os, vtkIndent indent) override;
51
53
57 vtkDataSet* GetInput() { return this->GetInput(0); }
59
61
66 vtkGetMacro(MergePoints, vtkTypeBool);
67 vtkSetMacro(MergePoints, vtkTypeBool);
68 vtkBooleanMacro(MergePoints, vtkTypeBool);
70
72
79 vtkSetClampMacro(Tolerance, double, 0.0, VTK_DOUBLE_MAX);
80 vtkGetMacro(Tolerance, double);
82
84
89 vtkSetMacro(ToleranceIsAbsolute, bool);
90 vtkGetMacro(ToleranceIsAbsolute, bool);
91 vtkBooleanMacro(ToleranceIsAbsolute, bool);
93
98
104
106
111 vtkSetClampMacro(OutputPointsPrecision, int, SINGLE_PRECISION, DEFAULT_PRECISION);
112 vtkGetMacro(OutputPointsPrecision, int);
114
115protected:
118
119 // Usual data generation method
122 int FillInputPortInformation(int port, vtkInformation* info) override;
123
124 // list of data sets to append together.
125 // Here as a convenience. It is a copy of the input array.
127
128 // If true we will attempt to merge points. Must also not have
129 // ghost cells defined.
131
133 double Tolerance;
134
135 // If true, tolerance is used as is. If false, tolerance is multiplied by
136 // the diagonal of the bounding box of the input.
138
139private:
140 vtkAppendFilter(const vtkAppendFilter&) = delete;
141 void operator=(const vtkAppendFilter&) = delete;
142
143 // Get all input data sets that have points, cells, or both.
144 // Caller must delete the returned vtkDataSetCollection.
145 vtkDataSetCollection* GetNonEmptyInputs(vtkInformationVector** inputVector);
146
147 void AppendArrays(int attributesType, vtkInformationVector** inputVector, vtkIdType* globalIds,
148 vtkUnstructuredGrid* output, vtkIdType totalNumberOfElements);
149};
150
151#endif
appends one or more datasets together into a single unstructured grid
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkDataSetCollection * InputList
void RemoveInputData(vtkDataSet *in)
Remove a dataset from the list of data to append.
vtkDataSet * GetInput()
Get any input of this filter.
vtkTypeBool MergePoints
int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
~vtkAppendFilter() override
static vtkAppendFilter * New()
vtkDataSetCollection * GetInputList()
Returns a copy of the input array.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkDataSet * GetInput(int idx)
Get any input of this filter.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
represent and manipulate attribute data in a dataset
maintain an unordered list of dataset objects
abstract class to specify dataset behavior
Definition: vtkDataSet.h:57
a simple class to control print indentation
Definition: vtkIndent.h:34
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only unstructured grid as output.
dataset represents arbitrary combinations of all possible cell types
int vtkTypeBool
Definition: vtkABI.h:69
int vtkIdType
Definition: vtkType.h:332
#define VTK_DOUBLE_MAX
Definition: vtkType.h:165