VTK  9.3.1
vtkClipConvexPolyData.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
15 #ifndef vtkClipConvexPolyData_h
16 #define vtkClipConvexPolyData_h
17 
18 #include "vtkFiltersGeneralModule.h" // For export macro
19 #include "vtkPolyDataAlgorithm.h"
20 
21 VTK_ABI_NAMESPACE_BEGIN
22 class vtkPlaneCollection;
23 class vtkPlane;
24 class vtkClipConvexPolyDataInternals;
25 
26 class VTKFILTERSGENERAL_EXPORT vtkClipConvexPolyData : public vtkPolyDataAlgorithm
27 {
28 public:
29  static vtkClipConvexPolyData* New();
31  void PrintSelf(ostream& os, vtkIndent indent) override;
32 
34 
38  void SetPlanes(vtkPlaneCollection* planes);
39  vtkGetObjectMacro(Planes, vtkPlaneCollection);
41 
46  vtkMTimeType GetMTime() override;
47 
48 protected:
50  ~vtkClipConvexPolyData() override;
51 
52  // The method that does it all...
53  int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
54  vtkInformationVector* outputVector) override;
55 
60  void ClipWithPlane(vtkPlane* p, double tolerance);
61 
65  bool HasDegeneracies(vtkPlane* p);
66 
70  void ClearInternals();
71 
75  void ClearNewVertices();
76 
80  void RemoveEmptyPolygons();
81 
83  vtkClipConvexPolyDataInternals* Internal;
84 
85 private:
87  void operator=(const vtkClipConvexPolyData&) = delete;
88 };
89 
90 VTK_ABI_NAMESPACE_END
91 #endif
Store vtkAlgorithm input/output information.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:270
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
maintain a list of planes
static vtkPolyDataAlgorithm * New()
vtkPlaneCollection * Planes
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:28
virtual vtkMTimeType GetMTime()
Return this object's modified time.
perform various plane computations
Definition: vtkPlane.h:25
vtkClipConvexPolyDataInternals * Internal
Store zero or more vtkInformation instances.
clip any dataset with user-specified implicit function or input scalar data
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.