Drake Designer
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Macros Pages
vtkLidarSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkLidarSource.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 =========================================================================*/
15 // .NAME vtkLidarSource -
16 // .SECTION Description
17 //
18 
19 #ifndef __vtkLidarSource_h
20 #define __vtkLidarSource_h
21 
22 #include <vtkPolyDataAlgorithm.h>
23 
24 #include <vtkDRCFiltersModule.h>
25 
26 class vtkTransform;
27 
28 class VTKDRCFILTERS_EXPORT vtkLidarSource : public vtkPolyDataAlgorithm
29 {
30 public:
31  vtkTypeMacro(vtkLidarSource, vtkPolyDataAlgorithm);
32  void PrintSelf(ostream& os, vtkIndent indent);
33 
34  static vtkLidarSource *New();
35 
36 
37  void Poll();
38 
39  void Start();
40  void Stop();
41 
42  vtkGetVector2Macro(DistanceRange, double);
43  vtkSetVector2Macro(DistanceRange, double);
44 
45  vtkGetVector2Macro(HeightRange, double);
46  vtkSetVector2Macro(HeightRange, double);
47 
48  void SetEdgeAngleThreshold(double threshold);
49  double GetEdgeAngleThreshold();
50 
51  int GetCurrentRevolution();
52  void GetDataForRevolution(int revolution, vtkPolyData* polyData);
53 
54  void GetDataForHistory(int numberOfScanLines, vtkPolyData* polyData);
55 
56  int GetCurrentScanLine();
57  void GetDataForScanLine(int scanLine, vtkPolyData* polyData);
58  vtkIdType GetCurrentScanTime();
59 
60  void subscribe(const char* channelName);
61 
62  void setCoordinateFrame(const char* coordinateFrame);
63 
64  void InitBotConfig(const char* filename);
65 
66  void GetTransform(const char* fromFrame, const char* toFrame, vtkIdType utime, vtkTransform* transform);
67 
68  static void GetBotRollPitchYaw(vtkTransform* transform, double rpy[3]);
69  static void GetBotQuaternion(vtkTransform* transform, double wxyz[4]);
70 
71 protected:
72 
73 
74  virtual int RequestInformation(vtkInformation *request,
75  vtkInformationVector **inputVector,
76  vtkInformationVector *outputVector);
77 
78  virtual int RequestData(vtkInformation *request,
79  vtkInformationVector **inputVector,
80  vtkInformationVector *outputVector);
81 
83  virtual ~vtkLidarSource();
84 
85  double DistanceRange[2];
87  double HeightRange[2];
88 
89 private:
90  vtkLidarSource(const vtkLidarSource&); // Not implemented.
91  void operator=(const vtkLidarSource&); // Not implemented.
92 
93  class vtkInternal;
94  vtkInternal * Internal;
95 };
96 
97 #endif
double EdgeAngleThreshold
#define VTKDRCFILTERS_EXPORT