VTK
vtkPlaneSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkPlaneSource.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 =========================================================================*/
53 #ifndef vtkPlaneSource_h
54 #define vtkPlaneSource_h
55 
56 #include "vtkFiltersSourcesModule.h" // For export macro
57 #include "vtkPolyDataAlgorithm.h"
58 
60 {
61 public:
62  void PrintSelf(ostream& os, vtkIndent indent);
64 
67  static vtkPlaneSource *New();
68 
70 
71  vtkSetMacro(XResolution,int);
72  vtkGetMacro(XResolution,int);
74 
76 
77  vtkSetMacro(YResolution,int);
78  vtkGetMacro(YResolution,int);
80 
82 
83  void SetResolution(const int xR, const int yR);
84  void GetResolution(int& xR,int& yR) {
85  xR=this->XResolution; yR=this->YResolution;};
87 
89 
90  vtkSetVector3Macro(Origin,double);
91  vtkGetVectorMacro(Origin,double,3);
93 
95 
96  void SetPoint1(double x, double y, double z);
97  void SetPoint1(double pnt[3]);
98  vtkGetVectorMacro(Point1,double,3);
100 
102 
103  void SetPoint2(double x, double y, double z);
104  void SetPoint2(double pnt[3]);
105  vtkGetVectorMacro(Point2,double,3);
107 
109 
112  void SetCenter(double x, double y, double z);
113  void SetCenter(double center[3]);
114  vtkGetVectorMacro(Center,double,3);
116 
118 
121  void SetNormal(double nx, double ny, double nz);
122  void SetNormal(double n[3]);
123  vtkGetVectorMacro(Normal,double,3);
125 
128  void Push(double distance);
129 
131 
135  vtkSetMacro(OutputPointsPrecision,int);
136  vtkGetMacro(OutputPointsPrecision,int);
138 
139 protected:
140  vtkPlaneSource();
142 
144 
147  double Origin[3];
148  double Point1[3];
149  double Point2[3];
150  double Normal[3];
151  double Center[3];
153 
154  int UpdatePlane(double v1[3], double v2[3]);
155 private:
156  vtkPlaneSource(const vtkPlaneSource&); // Not implemented.
157  void operator=(const vtkPlaneSource&); // Not implemented.
158 };
159 
160 #endif
void GetResolution(int &xR, int &yR)
Store vtkAlgorithm input/output information.
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
static vtkPolyDataAlgorithm * New()
void PrintSelf(ostream &os, vtkIndent indent)
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:38
#define VTKFILTERSSOURCES_EXPORT
create an array of quadrilaterals located in a plane
Store zero or more vtkInformation instances.