Loading [MathJax]/jax/output/NativeMML/config.js
Isis 3 Developer Reference
SunShadowTool.h
Go to the documentation of this file.
1 #ifndef SunShadowTool_h
2 #define SunShadowTool_h
3 
4 #include "Tool.h"
5 
6 #include <QAction>
7 
8 #include "IString.h"
9 #include "TableMainWindow.h"
10 
11 class QCheckBox;
12 class QComboBox;
13 class QDialog;
14 class QLineEdit;
15 class QMenu;
16 class QString;
17 
18 namespace Isis {
19  class Angle;
20  class Distance;
21  class MdiCubeViewport;
22  class SurfacePoint;
23 
39  class SunShadowTool : public Tool {
40  Q_OBJECT
41 
42  public:
43  SunShadowTool(QWidget *parent);
44  void addTo(QMenu *menu);
45 
46  void paintViewport(MdiCubeViewport *vp, QPainter *painter);
47 
48  protected slots:
49  virtual void mouseMove(QPoint p);
50  virtual void mouseButtonPress(QPoint p, Qt::MouseButton s);
51  virtual void mouseButtonRelease(QPoint p, Qt::MouseButton s);
52 
53  protected:
54  QWidget *createToolBarWidget(QStackedWidget *parent);
56 
57  void updateTool();
58 
59  private slots:
60  void updateShadowHeightEdit();
61  void reinitialize();
62 
63  private:
64  void addRow();
65  void recalculateShadowHeight();
66  void updateRow(int row);
67 
68  private:
70  QLineEdit *m_shadowHeightLineEdit;
72  QComboBox *m_unitsComboBox;
74  QCheckBox *m_drawInSunDirection;
75 
79  enum TableColumnIndex {
81  StartLatIndex = 2,
83  StartLonIndex,
85  EndLatIndex,
87  EndLonIndex,
89  StartSampIndex,
91  StartLineIndex,
93  EndSampIndex,
95  EndLineIndex,
97  ShadowLengthKmIndex,
99  ShadowLengthMIndex,
101  ShadowHeightKmIndex,
103  ShadowHeightMIndex,
105  IncidenceAngleDegreesIndex,
107  IncidenceAngleRadiansIndex,
109  PathIndex,
111  FileNameIndex
112  };
113 
115  double m_startSamp;
117  double m_startLine;
119  SurfacePoint *m_startSurfacePoint;
120 
122  double m_endSamp;
124  double m_endLine;
126  SurfacePoint *m_endSurfacePoint;
127 
129  Angle *m_incidenceAngle;
130 
132  Distance *m_shadowHeight;
134  Distance *m_shadowLength;
135 
137  QString m_path;
139  QString m_fileName;
140 
142  TableMainWindow *m_tableWin;
144  bool m_enabled;
149  bool m_tracking;
151  Angle *m_trackingAngle;
152  };
153 
154 };
155 
156 #endif
This class defines a body-fixed surface point.
Definition: SurfacePoint.h:148
Cube display widget for certain Isis MDI applications.
Definition: MdiCubeViewport.h:53
virtual void mouseButtonPress(QPoint p, Qt::MouseButton s)
When the mouse left button is pressed we start tracking.
Definition: SunShadowTool.cpp:269
virtual void mouseButtonRelease(QPoint p, Qt::MouseButton s)
When the mouse left button is released we finish tracking.
Definition: SunShadowTool.cpp:301
void addTo(QMenu *menu)
Adds the measure action to the given menu.
Definition: SunShadowTool.cpp:174
QWidget * createToolBarWidget(QStackedWidget *parent)
Creates the widget (button) that goes on the tool bar.
Definition: SunShadowTool.cpp:118
Distance measurement, usually in meters.
Definition: Distance.h:47
virtual void mouseMove(QPoint p)
When the mouse moves, if we&#39;re tracking then we go ahead and update all of our calculated values for ...
Definition: SunShadowTool.cpp:212
void updateTool()
This enables/disables this tool&#39;s functionality based on the active viewport&#39;s compatibility.
Definition: SunShadowTool.cpp:588
QAction * toolPadAction(ToolPad *pad)
Create an action for activating this tool.
Definition: SunShadowTool.cpp:92
void paintViewport(MdiCubeViewport *vp, QPainter *painter)
Paint anything we need to on the viewport.
Definition: SunShadowTool.cpp:185
a subclass of the qisis mainwindow, tablemainwindow handles all of the table tasks.
Definition: TableMainWindow.h:57
Defines an angle and provides unit conversions.
Definition: Angle.h:62
Namespace for ISIS/Bullet specific routines.
Definition: Apollo.h:31
Base class for the Qisis tools.
Definition: Tool.h:81
Tool for measuring shadow heights.
Definition: SunShadowTool.h:39
SunShadowTool(QWidget *parent)
Construct a sun shadow tool.
Definition: SunShadowTool.cpp:35
Definition: ToolPad.h:14

U.S. Department of the Interior | U.S. Geological Survey
ISIS | Privacy & Disclaimers | Astrogeology Research Program
To contact us, please post comments and questions on the USGS Astrogeology Discussion Board
To report a bug, or suggest a feature go to: ISIS Github
File Modified: 07/12/2023 23:30:50