VTK
vtkLineSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkLineSource.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 =========================================================================*/
34 #ifndef vtkLineSource_h
35 #define vtkLineSource_h
36 
37 #include "vtkFiltersSourcesModule.h" // For export macro
38 #include "vtkPolyDataAlgorithm.h"
39 
40 class vtkPoints;
41 
42 class VTKFILTERSSOURCES_EXPORT vtkLineSource : public vtkPolyDataAlgorithm
43 {
44 public:
45  static vtkLineSource *New();
47  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
48 
50 
53  vtkSetVector3Macro(Point1,double);
54  vtkGetVectorMacro(Point1,double,3);
55  void SetPoint1(float[3]);
57 
59 
62  vtkSetVector3Macro(Point2,double);
63  vtkGetVectorMacro(Point2,double,3);
64  void SetPoint2(float[3]);
66 
68 
71  virtual void SetPoints(vtkPoints*);
72  vtkGetObjectMacro(Points,vtkPoints);
74 
76 
79  vtkSetClampMacro(Resolution,int,1,VTK_INT_MAX);
80  vtkGetMacro(Resolution,int);
82 
84 
89  vtkSetMacro(OutputPointsPrecision,int);
90  vtkGetMacro(OutputPointsPrecision,int);
92 
93 protected:
94  vtkLineSource(int res=1);
95  ~vtkLineSource() VTK_OVERRIDE;
96 
97  int RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *) VTK_OVERRIDE;
98  int RequestInformation(vtkInformation *, vtkInformationVector **, vtkInformationVector *) VTK_OVERRIDE;
99  double Point1[3];
100  double Point2[3];
101  int Resolution;
102  int OutputPointsPrecision;
103 
108  vtkPoints* Points;
109 
110 private:
111  vtkLineSource(const vtkLineSource&) VTK_DELETE_FUNCTION;
112  void operator=(const vtkLineSource&) VTK_DELETE_FUNCTION;
113 };
114 
115 #endif
Store vtkAlgorithm input/output information.
#define VTK_INT_MAX
Definition: vtkType.h:153
static vtkPolyDataAlgorithm * New()
Superclass for algorithms that produce only polydata as output.
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
create a line defined by two end points
Definition: vtkLineSource.h:42
Store zero or more vtkInformation instances.
represent and manipulate 3D points
Definition: vtkPoints.h:39
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.