VTK: Imaging/Core/vtkImageAppendComponents.h Source File

| VTK 9.3.1

vtkImageAppendComponents.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
26 #ifndef vtkImageAppendComponents_h
27 #define vtkImageAppendComponents_h
28
29 #include "vtkImagingCoreModule.h" // For export macro
30 #include "vtkThreadedImageAlgorithm.h"
31
32 VTK_ABI_NAMESPACE_BEGIN
33 class VTKIMAGINGCORE_EXPORT vtkImageAppendComponents : public vtkThreadedImageAlgorithm
34 {
35 public:
36 static vtkImageAppendComponents* New();
37 vtkTypeMacro(vtkImageAppendComponents, vtkThreadedImageAlgorithm);
38 void PrintSelf(ostream& os, vtkIndent indent) override;
39
46 virtual void ReplaceNthInputConnection(int idx, vtkAlgorithmOutput* input);
47
49
54 void SetInputData(int num, vtkDataObject* input);
55 void SetInputData(vtkDataObject* input) { this->SetInputData(0, input); }
57
59
64 vtkDataObject* GetInput(int num);
65 vtkDataObject* GetInput() { return this->GetInput(0); }
67
73 int GetNumberOfInputs() { return this->GetNumberOfInputConnections(0); }
74
75 protected:
76 vtkImageAppendComponents() = default;
77 ~vtkImageAppendComponents() override = default;
78
79 int RequestInformation(vtkInformation*, vtkInformationVector**, vtkInformationVector*) override;
80
81 void ThreadedRequestData(vtkInformation* request, vtkInformationVector** inputVector,
82 vtkInformationVector* outputVector, vtkImageData*** inData, vtkImageData** outData, int ext[6],
83 int id) override;
84
85 // Implement methods required by vtkAlgorithm.
86 int FillInputPortInformation(int, vtkInformation*) override;
87
88 private:
89 vtkImageAppendComponents(const vtkImageAppendComponents&) = delete;
90 void operator=(const vtkImageAppendComponents&) = delete;
91 };
92
93 VTK_ABI_NAMESPACE_END
94 #endif
vtkAlgorithmOutput
Proxy object to connect input/output ports.
Definition: vtkAlgorithmOutput.h:41
vtkAlgorithm::GetNumberOfInputConnections
int GetNumberOfInputConnections(int port)
Get the number of inputs currently connected to a port.
vtkDataObject
general representation of visualization data
Definition: vtkDataObject.h:64
vtkImageAppendComponents
Collects components from two inputs into one output.
Definition: vtkImageAppendComponents.h:34
vtkImageAppendComponents::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkImageAppendComponents::SetInputData
void SetInputData(int num, vtkDataObject *input)
Assign a data object as input.
vtkImageAppendComponents::ThreadedRequestData
void ThreadedRequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector, vtkImageData ***inData, vtkImageData **outData, int ext[6], int id) override
If the subclass does not define an Execute method, then the task will be broken up,...
vtkImageAppendComponents::vtkImageAppendComponents
vtkImageAppendComponents()=default
vtkImageAppendComponents::ReplaceNthInputConnection
virtual void ReplaceNthInputConnection(int idx, vtkAlgorithmOutput *input)
Replace one of the input connections with a new input.
vtkImageAppendComponents::GetInput
vtkDataObject * GetInput()
Get one input to this filter.
Definition: vtkImageAppendComponents.h:65
vtkImageAppendComponents::RequestInformation
int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
Subclasses can reimplement this method to collect information from their inputs and set information f...
vtkImageAppendComponents::New
static vtkImageAppendComponents * New()
vtkImageAppendComponents::SetInputData
void SetInputData(vtkDataObject *input)
Assign a data object as input.
Definition: vtkImageAppendComponents.h:55
vtkImageAppendComponents::GetInput
vtkDataObject * GetInput(int num)
Get one input to this filter.
vtkImageAppendComponents::GetNumberOfInputs
int GetNumberOfInputs()
Get the number of inputs to this filter.
Definition: vtkImageAppendComponents.h:73
vtkImageAppendComponents::~vtkImageAppendComponents
~vtkImageAppendComponents() override=default
vtkImageAppendComponents::FillInputPortInformation
int FillInputPortInformation(int, vtkInformation *) override
These method should be reimplemented by subclasses that have more than a single input or single outpu...
vtkImageData
topologically and geometrically regular array of data
Definition: vtkImageData.h:52
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:38
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:40
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:72
vtkThreadedImageAlgorithm
Generic filter that has one input.
Definition: vtkThreadedImageAlgorithm.h:34
vtkThreadedImageAlgorithm.h