VTK
vtkSelectEnclosedPoints.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkSelectEnclosedPoints.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 =========================================================================*/
45 #ifndef __vtkSelectEnclosedPoints_h
46 #define __vtkSelectEnclosedPoints_h
47 
48 #include "vtkDataSetAlgorithm.h"
49 
51 class vtkCellLocator;
52 class vtkIdList;
53 class vtkGenericCell;
54 
55 
57 {
58 public:
60 
62  void PrintSelf(ostream& os, vtkIndent indent);
64 
66  static vtkSelectEnclosedPoints *New();
67 
69 
72  void SetSurface(vtkPolyData *pd);
73  void SetSurfaceConnection(vtkAlgorithmOutput* algOutput);
75 
77 
78  vtkPolyData *GetSurface();
79  vtkPolyData *GetSurface(vtkInformationVector *sourceInfo);
81 
83 
86  vtkSetMacro(InsideOut,int);
87  vtkBooleanMacro(InsideOut,int);
88  vtkGetMacro(InsideOut,int);
90 
92 
94  vtkSetMacro(CheckSurface,int);
95  vtkBooleanMacro(CheckSurface,int);
96  vtkGetMacro(CheckSurface,int);
98 
101  int IsInside(vtkIdType inputPtId);
102 
104 
106  vtkSetClampMacro(Tolerance,double,0.0,VTK_LARGE_FLOAT);
107  vtkGetMacro(Tolerance,double);
109 
111 
115  void Initialize(vtkPolyData *surface);
116  int IsInsideSurface(double x, double y, double z);
117  int IsInsideSurface(double x[3]);
118  void Complete();
120 
121 protected:
124 
127  double Tolerance;
128 
129  int IsSurfaceClosed(vtkPolyData *surface);
131 
132  // Internal structures for accelerating the intersection test
137  double Bounds[6];
138  double Length;
139 
141  virtual int FillInputPortInformation(int, vtkInformation *);
142 
143  virtual void ReportReferences(vtkGarbageCollector*);
144 
145 private:
146  vtkSelectEnclosedPoints(const vtkSelectEnclosedPoints&); // Not implemented.
147  void operator=(const vtkSelectEnclosedPoints&); // Not implemented.
148 };
149 
150 #endif
virtual int FillInputPortInformation(int port, vtkInformation *info)
vtkUnsignedCharArray * InsideOutsideArray
#define VTK_GRAPHICS_EXPORT
Store vtkAlgorithm input/output information.
mark points as to whether they are inside a closed surface
int vtkIdType
Definition: vtkType.h:255
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:81
Detect and break reference loops.
provides thread-safe access to cells
Proxy object to connect input/output ports.
virtual void ReportReferences(vtkGarbageCollector *)
octree-based spatial search object to quickly locate cells
a simple class to control print indentation
Definition: vtkIndent.h:37
list of point or cell ids
Definition: vtkIdList.h:34
virtual int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *)
dynamic, self-adjusting array of unsigned char
#define VTK_LARGE_FLOAT
Definition: vtkType.h:149
Store zero or more vtkInformation instances.
void PrintSelf(ostream &os, vtkIndent indent)
Superclass for algorithms that produce output of the same type as input.
static vtkDataSetAlgorithm * New()