VTK
vtkPlanes.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPlanes.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 =========================================================================*/
43 #ifndef vtkPlanes_h
44 #define vtkPlanes_h
45 
46 #include "vtkCommonDataModelModule.h" // For export macro
47 #include "vtkImplicitFunction.h"
48 
49 class vtkPlane;
50 class vtkPoints;
51 class vtkDataArray;
52 
54 {
55 public:
56  static vtkPlanes *New();
58  void PrintSelf(ostream& os, vtkIndent indent);
59 
61 
62  double EvaluateFunction(double x[3]);
63  double EvaluateFunction(double x, double y, double z)
64  {return this->vtkImplicitFunction::EvaluateFunction(x, y, z); } ;
66 
68  void EvaluateGradient(double x[3], double n[3]);
69 
71 
73  virtual void SetPoints(vtkPoints*);
74  vtkGetObjectMacro(Points,vtkPoints);
76 
78 
80  void SetNormals(vtkDataArray* normals);
81  vtkGetObjectMacro(Normals,vtkDataArray);
83 
86  void SetFrustumPlanes(double planes[24]);
87 
89 
93  void SetBounds(const double bounds[6]);
94  void SetBounds(double xmin, double xmax, double ymin, double ymax,
95  double zmin, double zmax);
97 
99  int GetNumberOfPlanes();
100 
102 
106  vtkPlane *GetPlane(int i);
107  void GetPlane(int i, vtkPlane *plane);
109 
110 protected:
111  vtkPlanes();
112  ~vtkPlanes();
113 
117 
118 private:
119  double Planes[24];
120  double Bounds[6];
121 
122 private:
123  vtkPlanes(const vtkPlanes&); // Not implemented.
124  void operator=(const vtkPlanes&); // Not implemented.
125 };
126 
127 #endif
128 
129 
abstract interface for implicit functions
virtual double EvaluateFunction(double x[3])=0
double EvaluateFunction(double x, double y, double z)
Definition: vtkPlanes.h:63
vtkPlane * Plane
Definition: vtkPlanes.h:116
implicit function for convex set of planes
Definition: vtkPlanes.h:53
virtual void EvaluateGradient(double x[3], double g[3])=0
vtkPoints * Points
Definition: vtkPlanes.h:114
a simple class to control print indentation
Definition: vtkIndent.h:38
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
perform various plane computations
Definition: vtkPlane.h:36
vtkDataArray * Normals
Definition: vtkPlanes.h:115
void PrintSelf(ostream &os, vtkIndent indent)
static vtkObject * New()
#define VTKCOMMONDATAMODEL_EXPORT
represent and manipulate 3D points
Definition: vtkPoints.h:38