VTK
vtkIntersectionPolyDataFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkIntersectionPolyDataFilter.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 =========================================================================*/
60 #ifndef vtkIntersectionPolyDataFilter_h
61 #define vtkIntersectionPolyDataFilter_h
62 
63 #include "vtkFiltersGeneralModule.h" // For export macro
64 #include "vtkPolyDataAlgorithm.h"
65 
66 class VTKFILTERSGENERAL_EXPORT vtkIntersectionPolyDataFilter :
68 {
69 public:
72  void PrintSelf(ostream &os, vtkIndent indent) override;
73 
75 
78  vtkGetMacro(NumberOfIntersectionPoints, int);
79  vtkGetMacro(NumberOfIntersectionLines, int);
81 
83 
87  vtkGetMacro(SplitFirstOutput, vtkTypeBool);
88  vtkSetMacro(SplitFirstOutput, vtkTypeBool);
89  vtkBooleanMacro(SplitFirstOutput, vtkTypeBool);
91 
93 
97  vtkGetMacro(SplitSecondOutput, vtkTypeBool);
98  vtkSetMacro(SplitSecondOutput, vtkTypeBool);
99  vtkBooleanMacro(SplitSecondOutput, vtkTypeBool);
101 
103 
107  vtkGetMacro(ComputeIntersectionPointArray, vtkTypeBool);
108  vtkSetMacro(ComputeIntersectionPointArray, vtkTypeBool);
109  vtkBooleanMacro(ComputeIntersectionPointArray, vtkTypeBool);
111 
113 
116  vtkGetMacro(CheckInput, vtkTypeBool);
117  vtkSetMacro(CheckInput, vtkTypeBool);
118  vtkBooleanMacro(CheckInput, vtkTypeBool);
120 
122 
126  vtkGetMacro(CheckMesh, vtkTypeBool);
127  vtkSetMacro(CheckMesh, vtkTypeBool);
128  vtkBooleanMacro(CheckMesh, vtkTypeBool);
130 
132 
137  vtkGetMacro(Status, int);
139 
141 
144  vtkGetMacro(Tolerance, double);
145  vtkSetMacro(Tolerance, double);
147 
149 
154  vtkGetMacro(RelativeSubtriangleArea, double);
155  vtkSetMacro(RelativeSubtriangleArea, double);
157 
168  static int TriangleTriangleIntersection(double p1[3], double q1[3],
169  double r1[3], double p2[3],
170  double q2[3], double r2[3],
171  int &coplanar, double pt1[3],
172  double pt2[3], double surfaceid[2],
173  double tolerance);
174 
179  static void CleanAndCheckSurface(vtkPolyData *pd, double stats[2],
180  double tolerance);
181 
185  static void CleanAndCheckInput(vtkPolyData *pd, double tolerance);
186 
187 
188 protected:
189  vtkIntersectionPolyDataFilter(); //Constructor
190  ~vtkIntersectionPolyDataFilter() override; //Destructor
191 
193  vtkInformationVector*) override; //Update
194  int FillInputPortInformation(int, vtkInformation*) override; //Input,Output
195 
196 private:
198  void operator=(const vtkIntersectionPolyDataFilter&) = delete;
199 
200  int NumberOfIntersectionPoints;
201  int NumberOfIntersectionLines;
202  vtkTypeBool SplitFirstOutput;
203  vtkTypeBool SplitSecondOutput;
204  vtkTypeBool ComputeIntersectionPointArray;
205  vtkTypeBool CheckMesh;
206  vtkTypeBool CheckInput;
207  int Status;
208  double Tolerance;
209  double RelativeSubtriangleArea;
210 
211  class Impl; //Implementation class
212 };
213 
214 
215 #endif // vtkIntersectionPolyDataFilter_h
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:79
static vtkPolyDataAlgorithm * New()
int vtkTypeBool
Definition: vtkABI.h:69
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkIntersectionPolyDataFilter computes the intersection between two vtkPolyData objects.
int FillInputPortInformation(int port, vtkInformation *info) override
Fill the input port information objects for this algorithm.
Store zero or more vtkInformation instances.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.