VTK  9.6.20260109
vtkTableBasedClipDataSet.h
Go to the documentation of this file.
1// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2// SPDX-FileCopyrightText: Copyright (c) 2000 - 2009, Lawrence Livermore National Security, LLC
3// SPDX-License-Identifier: BSD-3-Clause
4
118
119#ifndef vtkTableBasedClipDataSet_h
120#define vtkTableBasedClipDataSet_h
121
122#include "vtkFiltersGeneralModule.h" // For export macro
123#include "vtkIncrementalPointLocator.h" // For vtkIncrementalPointLocator
125#include "vtkWeakPointer.h" // Needed for weak pointer to the vtkIncrementalPointLocator
126
127VTK_ABI_NAMESPACE_BEGIN
129class vtkDoubleArray;
131class vtkPolyData;
132
133class VTKFILTERSGENERAL_EXPORT vtkTableBasedClipDataSet : public vtkUnstructuredGridAlgorithm
134{
135public:
137 void PrintSelf(ostream& os, vtkIndent indent) override;
138
144
149
151
158 vtkSetMacro(InsideOut, vtkTypeBool);
159 vtkGetMacro(InsideOut, vtkTypeBool);
160 vtkBooleanMacro(InsideOut, vtkTypeBool);
162
164
170 vtkSetMacro(Value, double);
171 vtkGetMacro(Value, double);
173
175
180 vtkSetMacro(UseValueAsOffset, bool);
181 vtkGetMacro(UseValueAsOffset, bool);
182 vtkBooleanMacro(UseValueAsOffset, bool);
184
186
194
196
202 vtkSetMacro(GenerateClipScalars, vtkTypeBool);
203 vtkGetMacro(GenerateClipScalars, vtkTypeBool);
204 vtkBooleanMacro(GenerateClipScalars, vtkTypeBool);
206
208
216 vtkSetMacro(GenerateClipPointTypes, bool);
217 vtkGetMacro(GenerateClipPointTypes, bool);
218 vtkBooleanMacro(GenerateClipPointTypes, bool);
220
222
228 vtkSetClampMacro(MergeTolerance, double, 0.0001, 0.25);
229 vtkGetMacro(MergeTolerance, double);
231
233
241
246
248
254 vtkGetMacro(OutputPointsPrecision, int);
256
258
266 vtkSetClampMacro(BatchSize, unsigned int, 1, VTK_INT_MAX);
267 vtkGetMacro(BatchSize, unsigned int);
269
271
278
279protected:
282
284 int FillInputPortInformation(int port, vtkInformation* info) override;
285
286private:
292 void ClipDataSet(vtkDataSet* pDataSet, vtkUnstructuredGrid* outputUG);
293
300 void ClipPolyData(vtkPolyData* inputGrid, vtkImplicitFunction* implicitFunction,
301 vtkDoubleArray* scalars, double isoValue, vtkUnstructuredGrid* outputUG);
302
309 template <class TGrid>
310 void ClipTDataSet(TGrid* inputGrid, vtkImplicitFunction* implicitFunction,
311 vtkDoubleArray* scalars, double isoValue, vtkUnstructuredGrid* outputUG);
312
316 template <typename TGrid, typename TInputIdType, bool InsideOut>
318 TGrid* input, vtkImplicitFunction* implicitFunction, vtkDoubleArray* scalars, double isoValue);
319
323 static void InternalProgressCallbackFunction(vtkObject*, unsigned long, void* clientdata, void*);
324
328 void InternalProgressCallback(vtkAlgorithm* algorithm);
329
330protected:
331 vtkTypeBool InsideOut;
332 vtkTypeBool GenerateClipScalars;
334 bool UseValueAsOffset;
335 double Value;
339 unsigned int BatchSize;
340
342
344
345private:
347 void operator=(const vtkTableBasedClipDataSet&) = delete;
348
349 bool GenerateClipPointTypes;
350};
351
352VTK_ABI_NAMESPACE_END
353#endif
supports function callbacks
abstract class to specify dataset behavior
Definition vtkDataSet.h:166
dynamic, self-adjusting array of double
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:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
concrete dataset represents vertices, lines, polygons, and triangle strips
Hold a reference to a vtkObjectBase instance.
vtkTableBasedClipDataSet(vtkImplicitFunction *cf=nullptr)
static vtkTableBasedClipDataSet * New()
Create an instance with a user-specified implicit function, turning off IVARs InsideOut and GenerateC...
~vtkTableBasedClipDataSet() override
void SetLocator(vtkIncrementalPointLocator *locator)
Specify a spatial locator for merging points.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) override
This is called by the superclass.
virtual void SetClipFunction(vtkImplicitFunction *)
Set/Get the implicit function with which to perform the clipping operation.
vtkMTimeType GetMTime() override
Get the MTime for which the clip function are considered.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkUnstructuredGrid * GetClippedOutput()
Return the clipped output.
vtkWeakPointer< vtkIncrementalPointLocator > Locator
vtkCallbackCommand * InternalProgressObserver
dataset represents arbitrary combinations of all possible cell types
a weak reference to a vtkObject.
int vtkTypeBool
Definition vtkABI.h:64
vtkTypeUInt32 vtkMTimeType
Definition vtkType.h:323
#define VTK_INT_MAX
Definition vtkType.h:197
#define vtkTableBasedClipDataSet
Definition vtkmClip.h:25