VTK  9.4.20250421
vtkAppendPolyData.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
139#ifndef vtkAppendPolyData_h
140#define vtkAppendPolyData_h
141
142#include "vtkDeprecation.h" // For VTK_DEPRECATED_IN_9_5_0
143#include "vtkFiltersCoreModule.h" // For export macro
144#include "vtkPolyDataAlgorithm.h"
145
146VTK_ABI_NAMESPACE_BEGIN
147class vtkCellArray;
148class vtkDataArray;
149class vtkPoints;
150class vtkPolyData;
151
152class VTKFILTERSCORE_EXPORT vtkAppendPolyData : public vtkPolyDataAlgorithm
153{
154public:
156
158 void PrintSelf(ostream& os, vtkIndent indent) override;
159
161
167 vtkSetMacro(UserManagedInputs, vtkTypeBool);
168 vtkGetMacro(UserManagedInputs, vtkTypeBool);
169 vtkBooleanMacro(UserManagedInputs, vtkTypeBool);
171
177
183
185
189 vtkPolyData* GetInput() { return this->GetInput(0); }
191
196 void SetNumberOfInputs(int num);
197
198 // Set Nth input, should only be used when UserManagedInputs is true.
201
203
213 vtkSetMacro(ParallelStreaming, vtkTypeBool);
214 vtkGetMacro(ParallelStreaming, vtkTypeBool);
215 vtkBooleanMacro(ParallelStreaming, vtkTypeBool);
217
219
224 vtkSetMacro(OutputPointsPrecision, int);
225 vtkGetMacro(OutputPointsPrecision, int);
227
228 int ExecuteAppend(vtkPolyData* output, vtkPolyData* inputs[], int numInputs)
229 VTK_SIZEHINT(inputs, numInputs);
230
231protected:
234
235 // Flag for selecting parallel streaming behavior
238
239 // Usual data generation method
243
244 // An efficient templated way to append data.
245 VTK_DEPRECATED_IN_9_5_0("This function has been deprecated")
246 void AppendData(vtkDataArray* dest, vtkDataArray* src, vtkIdType offset);
247
248 // An efficient way to append cells.
249 VTK_DEPRECATED_IN_9_5_0("This function has been deprecated")
250 void AppendCells(vtkCellArray* dst, vtkCellArray* src, vtkIdType offset);
251
252private:
253 // hide the superclass' AddInput() from the user and the compiler
254 void AddInputData(vtkDataObject*)
255 {
256 vtkErrorMacro(<< "AddInput() must be called with a vtkPolyData not a vtkDataObject.");
257 }
258
259 vtkTypeBool UserManagedInputs;
260
261 vtkAppendPolyData(const vtkAppendPolyData&) = delete;
262 void operator=(const vtkAppendPolyData&) = delete;
263};
264
265VTK_ABI_NAMESPACE_END
266#endif
Proxy object to connect input/output ports.
appends one or more polygonal datasets together
int FillInputPortInformation(int, vtkInformation *) override
Fill the input port information objects for this algorithm.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int RequestUpdateExtent(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
void AddInputData(vtkPolyData *)
Add a dataset to the list of data to append.
void RemoveInputData(vtkPolyData *)
Remove a dataset from the list of data to append.
~vtkAppendPolyData() override
vtkTypeBool ParallelStreaming
int ExecuteAppend(vtkPolyData *output, vtkPolyData *inputs[], int numInputs)
vtkPolyData * GetInput(int idx)
Get any input of this filter.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
static vtkAppendPolyData * New()
void SetInputConnectionByNumber(int num, vtkAlgorithmOutput *input)
vtkPolyData * GetInput()
Get any input of this filter.
void SetNumberOfInputs(int num)
Directly set(allocate) number of inputs, should only be used when UserManagedInputs is true.
void SetInputDataByNumber(int num, vtkPolyData *ds)
object to represent cell connectivity
abstract superclass for arrays of numeric data
general representation of visualization data
a simple class to control print indentation
Definition vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
represent and manipulate 3D points
Definition vtkPoints.h:139
Superclass for algorithms that produce only polydata as output.
concrete dataset represents vertices, lines, polygons, and triangle strips
int vtkTypeBool
Definition vtkABI.h:64
#define VTK_DEPRECATED_IN_9_5_0(reason)
int vtkIdType
Definition vtkType.h:332
#define VTK_SIZEHINT(...)