VTK
vtkBooleanOperationPolyDataFilter.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkBooleanOperationPolyDataFilter.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=========================================================================*/
37#ifndef vtkBooleanOperationPolyDataFilter_h
38#define vtkBooleanOperationPolyDataFilter_h
39
40#include "vtkFiltersGeneralModule.h" // For export macro
42
43#include "vtkDataSetAttributes.h" // Needed for CopyCells() method
44
45class vtkIdList;
46
47class VTKFILTERSGENERAL_EXPORT vtkBooleanOperationPolyDataFilter : public vtkPolyDataAlgorithm
48{
49public:
54
57
58 void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
59
61 {
62 VTK_UNION=0,
64 VTK_DIFFERENCE
65 };
66
68
71 vtkSetClampMacro( Operation, int, VTK_UNION, VTK_DIFFERENCE );
72 vtkGetMacro( Operation, int );
74 { this->SetOperation( VTK_UNION ); }
76 { this->SetOperation( VTK_INTERSECTION ); }
78 { this->SetOperation( VTK_DIFFERENCE ); }
80
82
86 vtkSetMacro( ReorientDifferenceCells, int );
87 vtkGetMacro( ReorientDifferenceCells, int );
88 vtkBooleanMacro( ReorientDifferenceCells, int );
90
92
96 vtkSetMacro(Tolerance, double);
97 vtkGetMacro(Tolerance, double);
99
100protected:
103
107 void SortPolyData(vtkPolyData* input, vtkIdList* intersectionList,
108 vtkIdList* unionList);
109
110 int RequestData(vtkInformation*, vtkInformationVector**, vtkInformationVector*) VTK_OVERRIDE;
111 int FillInputPortInformation(int, vtkInformation*) VTK_OVERRIDE;
112
113private:
115 void operator=(const vtkBooleanOperationPolyDataFilter&) VTK_DELETE_FUNCTION;
116
122 void CopyCells(vtkPolyData* in, vtkPolyData* out, int idx,
123 vtkDataSetAttributes::FieldList & pointFieldList,
124 vtkDataSetAttributes::FieldList & cellFieldList,
125 vtkIdList* cellIds, bool reverseCells);
126
131 double Tolerance;
132
137 int Operation;
138
140
144 int ReorientDifferenceCells;
145};
147
148#endif
Computes the boundary of the union, intersection, or difference volume computed from the volumes defi...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static vtkBooleanOperationPolyDataFilter * New()
Construct object that computes the boolean surface.
represent and manipulate attribute data in a dataset
list of point or cell ids
Definition: vtkIdList.h:37
a simple class to control print indentation
Definition: vtkIndent.h:40
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Superclass for algorithms that produce only polydata as output.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:86
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.