VTK  9.1.0
vtkGenericClip.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkGenericClip.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=========================================================================*/
80#ifndef vtkGenericClip_h
81#define vtkGenericClip_h
82
83#include "vtkFiltersGenericModule.h" // For export macro
85
87
88class vtkPointData;
89class vtkCellData;
91
92class VTKFILTERSGENERIC_EXPORT vtkGenericClip : public vtkUnstructuredGridAlgorithm
93{
94public:
96 void PrintSelf(ostream& os, vtkIndent indent) override;
97
103
105
110 vtkSetMacro(Value, double);
111 vtkGetMacro(Value, double);
113
115
123 vtkSetMacro(InsideOut, vtkTypeBool);
124 vtkGetMacro(InsideOut, vtkTypeBool);
125 vtkBooleanMacro(InsideOut, vtkTypeBool);
127
129
135 vtkGetObjectMacro(ClipFunction, vtkImplicitFunction);
137
139
145 vtkSetMacro(GenerateClipScalars, vtkTypeBool);
146 vtkGetMacro(GenerateClipScalars, vtkTypeBool);
147 vtkBooleanMacro(GenerateClipScalars, vtkTypeBool);
149
151
155 vtkSetMacro(GenerateClippedOutput, vtkTypeBool);
156 vtkGetMacro(GenerateClippedOutput, vtkTypeBool);
157 vtkBooleanMacro(GenerateClippedOutput, vtkTypeBool);
159
161
167 vtkSetClampMacro(MergeTolerance, double, 0.0001, 0.25);
168 vtkGetMacro(MergeTolerance, double);
170
172
176 virtual int GetNumberOfOutputs();
178
180
185 vtkGetObjectMacro(Locator, vtkIncrementalPointLocator);
187
193
198
200
204 vtkGetStringMacro(InputScalarsSelection);
205 void SelectInputScalars(const char* fieldName) { this->SetInputScalarsSelection(fieldName); }
207
208protected:
210 ~vtkGenericClip() override;
211
214
216
219 double Value;
221
224
226 vtkSetStringMacro(InputScalarsSelection);
227
228 // Used internal by vtkGenericAdaptorCell::Clip()
232
233private:
234 vtkGenericClip(const vtkGenericClip&) = delete;
235 void operator=(const vtkGenericClip&) = delete;
236};
237
238#endif
represent and manipulate cell attribute data
Definition: vtkCellData.h:142
clip any dataset with an implicit function or scalar data
vtkMTimeType GetMTime() override
Return the mtime also considering the locator and clip function.
vtkIncrementalPointLocator * Locator
vtkCellData * SecondaryCD
static vtkGenericClip * New()
Construct with user-specified implicit function; InsideOut turned off; value set to 0....
vtkPointData * InternalPD
~vtkGenericClip() override
vtkTypeBool GenerateClipScalars
vtkPointData * SecondaryPD
char * InputScalarsSelection
virtual int GetNumberOfOutputs()
Return the Clipped output.
vtkUnstructuredGrid * GetClippedOutput()
Return the Clipped output.
vtkTypeBool InsideOut
void SelectInputScalars(const char *fieldName)
If you want to clip by an arbitrary array, then set its name here.
virtual void SetClipFunction(vtkImplicitFunction *)
Specify the implicit function with which to perform the clipping.
vtkGenericClip(vtkImplicitFunction *cf=nullptr)
vtkTypeBool GenerateClippedOutput
int FillInputPortInformation(int, vtkInformation *) override
Fill the input port information objects for this algorithm.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
vtkImplicitFunction * ClipFunction
void CreateDefaultLocator()
Create default locator.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void SetLocator(vtkIncrementalPointLocator *locator)
Specify a spatial locator for merging points.
abstract interface for implicit functions
Abstract class in support of both point location and point insertion.
a simple class to control print indentation
Definition: vtkIndent.h:113
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
represent and manipulate point attribute data
Definition: vtkPointData.h:142
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
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:287