Isis 3 Programmer Reference
SunShadowTool.cpp
1 #include "IsisDebug.h"
2 #include "SunShadowTool.h"
3 
4 #include <QApplication>
5 #include <QComboBox>
6 #include <QCheckBox>
7 #include <QFileDialog>
8 #include <QHBoxLayout>
9 #include <QLineEdit>
10 #include <QMenu>
11 #include <QMenuBar>
12 #include <QMessageBox>
13 #include <QStatusBar>
14 #include <QStackedWidget>
15 #include <QTableWidget>
16 #include <QToolButton>
17 
18 #include "Angle.h"
19 #include "Camera.h"
20 #include "Distance.h"
21 #include "FileName.h"
22 #include "Latitude.h"
23 #include "Longitude.h"
24 #include "MdiCubeViewport.h"
25 #include "Projection.h"
26 #include "SurfacePoint.h"
27 #include "ToolPad.h"
28 
29 namespace Isis {
36  m_enabled = false;
37  m_tracking = false;
38  m_shadowHeight = NULL;
39  m_shadowLength = NULL;
40  m_trackingAngle = NULL;
41  m_drawInSunDirection = NULL;
42  m_startSurfacePoint = NULL;
43  m_endSurfacePoint = NULL;
44  m_incidenceAngle = NULL;
45 
46  m_tableWin = new TableMainWindow("Sun Shadow Measurements", parent);
48  m_tableWin->installEventFilter(this);
49 
50  m_tableWin->addToTable(false, "Feature\nName", "Feature Name");
51  m_tableWin->addToTable(false, "Feature\nType", "Feature Type");
52  m_tableWin->addToTable(true,
53  "Start\nLatitude:Start\nLongitude:End\nLatitude:End\nLongitude",
54  "Ground Range", -1, Qt::Horizontal,
55  "Start Latitude/Longitude to End Latitude/Longitude");
56  m_tableWin->addToTable(false,
57  "Start\nSample:Start\nLine:End\nSample:End\nLine",
58  "Pixel Range", -1, Qt::Horizontal,
59  "Start Sample/Line to End Sample/Line");
60  m_tableWin->addToTable(true, "Shadow Length\n(km)", "Shadow Length (km)");
61  m_tableWin->addToTable(true, "Shadow Length\n(m)", "Shadow Length (m)");
62  m_tableWin->addToTable(true, "Shadow Height\n(km)", "Shadow Height (km)");
63  m_tableWin->addToTable(true, "Shadow Height\n(m)", "Shadow Height (m)");
64  m_tableWin->addToTable(true, "Incidence Angle\n(degrees)",
65  "Incidence Angle (degrees)");
66  m_tableWin->addToTable(true, "Incidence Angle\n(radians)",
67  "Incidence Angle (radians)");
68  m_tableWin->addToTable(false, "Path", "Path");
69  m_tableWin->addToTable(false, "FileName", "FileName");
70  m_tableWin->addToTable(false, "Notes", "Notes");
71 
72  m_tableWin->setStatusMessage("Click, Drag, and Release to Measure a Line");
73 
74  connect(this, SIGNAL(viewportChanged()),
75  this, SLOT(reinitialize()));
76 
79  m_trackingAngle = new Angle;
82  m_incidenceAngle = new Angle;
83  }
84 
85 
93  QAction *action = new QAction(toolpad);
94  action->setIcon(QPixmap(toolIconDir() + "/sunshadow.png"));
95  action->setToolTip("Sun Shadow (U)");
96  action->setShortcut(Qt::Key_U);
97 
98  QString text =
99  "<b>Function:</b> Calculate heights or depths of features in the active "
100  "viewport given the measurement of a shadow. The shadow measurement "
101  "should originate from the top of the feature and end when the shadow "
102  "ends.\n"
103  "<p><b>Shortcut:</b> U</p> ";
104  action->setWhatsThis(text);
105 
106  return action;
107  }
108 
109 
118  QWidget *SunShadowTool::createToolBarWidget(QStackedWidget *parent) {
119  QWidget *hbox = new QWidget(parent);
120  QToolButton *showTableButton = new QToolButton(hbox);
121  showTableButton->setText("Table");
122  showTableButton->setToolTip("Record Measurement Data in Table");
123  QString text =
124  "<b>Function:</b> This button will bring up a table that will record "
125  "the starting and ending points of the line, along with the calculated "
126  "values for the two points on the image. To measure a shadow, "
127  "click on the first point and releasing the mouse at the second point."
128  "\n<p><b>Shortcut:</b> CTRL+M</p>";
129  showTableButton->setWhatsThis(text);
130  showTableButton->setShortcut(Qt::CTRL + Qt::Key_M);
131  connect(showTableButton, SIGNAL(clicked()), m_tableWin, SLOT(showTable()));
132  connect(showTableButton, SIGNAL(clicked()), m_tableWin, SLOT(syncColumns()));
133  connect(showTableButton, SIGNAL(clicked()), m_tableWin, SLOT(raise()));
134  showTableButton->setEnabled(true);
135 
136  m_shadowHeightLineEdit = new QLineEdit(hbox);
137  m_shadowHeightLineEdit->setText("");
138  m_shadowHeightLineEdit->setMaxLength(12);
139  m_shadowHeightLineEdit->setToolTip("Shadow Height");
140  text = "<b>Function: </b> Shows the height of the shadow drawn on "
141  "the image.";
142  m_shadowHeightLineEdit->setWhatsThis(text);
143  m_shadowHeightLineEdit->setReadOnly(true);
144 
145  m_unitsComboBox = new QComboBox(hbox);
146  m_unitsComboBox->setSizeAdjustPolicy(QComboBox::AdjustToContents);
147  m_unitsComboBox->addItem("Meters", Distance::Meters);
148  m_unitsComboBox->addItem("Kilometers", Distance::Kilometers);
149 
150  connect(m_unitsComboBox, SIGNAL(activated(int)),
151  this, SLOT(updateShadowHeightEdit()));
152 
153  m_drawInSunDirection = new QCheckBox("Draw in Sun Direction");
154  m_drawInSunDirection->setChecked(true);
155 
156  QHBoxLayout *layout = new QHBoxLayout(hbox);
157  layout->setMargin(0);
158  layout->addWidget(m_drawInSunDirection);
159  layout->addWidget(m_shadowHeightLineEdit);
160  layout->addWidget(m_unitsComboBox);
161  layout->addWidget(showTableButton);
162  layout->addStretch(1);
163  hbox->setLayout(layout);
164  return hbox;
165  }
166 
167 
175  }
176 
177 
185  void SunShadowTool::paintViewport(MdiCubeViewport *vp, QPainter *painter) {
186  if (vp == cubeViewport()) {
187  if (m_startSamp != Null && m_endSamp != Null &&
188  m_startLine != Null && m_endLine != Null) {
189  int vpStartX;
190  int vpStartY;
192  vpStartX, vpStartY);
193 
194  int vpEndX;
195  int vpEndY;
197  vpEndX, vpEndY);
198 
199  painter->setPen(QPen(Qt::red));
200  painter->drawLine(QPoint(vpStartX, vpStartY), QPoint(vpEndX, vpEndY));
201  }
202  }
203  }
204 
205 
212  void SunShadowTool::mouseMove(QPoint p) {
213  if (m_tracking && m_trackingAngle->isValid()) {
214  cubeViewport()->viewportToCube(p.x(), p.y(),
216 
217  if (m_drawInSunDirection->isChecked()) {
218  // Recalculate the end line based on our drawing angle...
219  // y = x * tan(angle) for the right triangle created from the
220  // user drawing a line.
221  //
222  // E
223  // / |
224  // / |
225  // / | L
226  // / |
227  // /A |
228  // S-------|
229  // S = Mouse Start Pos
230  // A = sun angle
231  // E = mouse end pos
232  // L = Line height of the triangle
233  // (needs calculated, L = m_endLine - m_startLine)
234  //
235  Angle verticalDown(90, Angle::Degrees);
236  Angle verticalUp(270, Angle::Degrees);
237  bool adjustLine = true;
238 
239  if (*m_trackingAngle == verticalDown ||
240  *m_trackingAngle == verticalUp) {
242 
243  adjustLine = false;
244  }
245 
246  if (adjustLine) {
249  }
250  }
251 
253 
254  if (m_tableWin->table()->rowCount()) {
255  updateRow(m_tableWin->table()->rowCount() - 1);
256  }
257 
258  cubeViewport()->viewport()->update();
259  }
260  }
261 
262 
269  void SunShadowTool::mouseButtonPress(QPoint p, Qt::MouseButton s) {
270  if (m_enabled && s == Qt::LeftButton) {
271  if (m_tableWin->isVisible())
272  addRow();
273 
274  reinitialize();
275 
276  cubeViewport()->viewportToCube(p.x(), p.y(),
278 
279  Camera *cam = cubeViewport()->cube()->camera();
280 
281  if (cam->SetImage(m_startSamp, m_startLine)) {
282  m_tracking = true;
284  }
285  else {
286  m_tracking = false;
287  m_startSamp = Null;
288  m_startLine = Null;
289  }
290  cubeViewport()->viewport()->update();
291  }
292  }
293 
294 
301  void SunShadowTool::mouseButtonRelease(QPoint p, Qt::MouseButton s) {
302  if (s == Qt::LeftButton && m_tracking) {
303  mouseMove(p);
304  }
305 
306  m_tracking = false;
307  }
308 
309 
310 
318  void SunShadowTool::updateRow(int row) {
319  ASSERT(row < m_tableWin->table()->rowCount());
320 
321  if (row >= m_tableWin->table()->rowCount() || !
322  m_tableWin->isVisible()) {
323  return;
324  }
325 
326  // Blank out the row to remove stuff left over from previous cvps
327  for (int c = 0; c < m_tableWin->table()->columnCount(); c++) {
328  m_tableWin->table()->item(row, c)->setText("");
329  }
330 
331  // Write all the new info to the current row
332  if (m_startSurfacePoint->Valid()) {
333  m_tableWin->table()->item(row, StartLatIndex)->setText(
334  QString::number(m_startSurfacePoint->GetLatitude().degrees()));
335  m_tableWin->table()->item(row, StartLonIndex)->setText(
336  QString::number(m_startSurfacePoint->GetLongitude().degrees()));
337  }
338  else {
339  m_tableWin->table()->item(row, StartLatIndex)->setText("N/A");
340  m_tableWin->table()->item(row, StartLonIndex)->setText("N/A");
341  }
342 
343  if (m_endSurfacePoint->Valid()) {
344  m_tableWin->table()->item(row, EndLatIndex)->setText(
345  QString::number(m_endSurfacePoint->GetLatitude().degrees()));
346  m_tableWin->table()->item(row, EndLonIndex)->setText(
347  QString::number(m_endSurfacePoint->GetLongitude().degrees()));
348  }
349  else {
350  m_tableWin->table()->item(row, EndLatIndex)->setText("N/A");
351  m_tableWin->table()->item(row, EndLonIndex)->setText("N/A");
352  }
353 
354  if (m_startSamp != Null && m_startLine != Null) {
355  m_tableWin->table()->item(row, StartSampIndex)->setText(
356  QString::number(m_startSamp));
357  m_tableWin->table()->item(row, StartLineIndex)->setText(
358  QString::number(m_startLine));
359  }
360  else {
361  m_tableWin->table()->item(row, StartSampIndex)->setText("N/A");
362  m_tableWin->table()->item(row, StartLineIndex)->setText("N/A");
363  }
364 
365  if (m_endSamp != Null && m_endLine != Null) {
366  m_tableWin->table()->item(row, EndSampIndex)->setText(
367  QString::number(m_endSamp));
368  m_tableWin->table()->item(row, EndLineIndex)->setText(
369  QString::number(m_endLine));
370  }
371  else {
372  m_tableWin->table()->item(row, EndSampIndex)->setText("N/A");
373  m_tableWin->table()->item(row, EndLineIndex)->setText("N/A");
374  }
375 
376  if (m_shadowLength->isValid()) {
377  m_tableWin->table()->item(row, ShadowLengthKmIndex)->setText(
378  QString::number(m_shadowLength->kilometers()));
379  m_tableWin->table()->item(row, ShadowLengthMIndex)->setText(
380  QString::number(m_shadowLength->meters()));
381  }
382  else {
383  m_tableWin->table()->item(row, ShadowLengthKmIndex)->setText("N/A");
384  m_tableWin->table()->item(row, ShadowLengthMIndex)->setText("N/A");
385  }
386 
387  if (m_shadowHeight->isValid()) {
388  m_tableWin->table()->item(row, ShadowHeightKmIndex)->setText(
389  QString::number(m_shadowHeight->kilometers()));
390  m_tableWin->table()->item(row, ShadowHeightMIndex)->setText(
391  QString::number(m_shadowHeight->meters()));
392  }
393  else {
394  m_tableWin->table()->item(row, ShadowHeightKmIndex)->setText("N/A");
395  m_tableWin->table()->item(row, ShadowHeightMIndex)->setText("N/A");
396  }
397 
398  if (m_incidenceAngle->isValid()) {
399  m_tableWin->table()->item(row, IncidenceAngleDegreesIndex)->setText(
400  QString::number(m_incidenceAngle->degrees()));
401  m_tableWin->table()->item(row, IncidenceAngleRadiansIndex)->setText(
402  QString::number(m_incidenceAngle->radians()));
403  }
404  else {
405  m_tableWin->table()->item(row, IncidenceAngleDegreesIndex)->setText("N/A");
406  m_tableWin->table()->item(row, IncidenceAngleRadiansIndex)->setText("N/A");
407  }
408 
409  m_tableWin->table()->item(row, PathIndex)->setText(m_path);
410  m_tableWin->table()->item(row, FileNameIndex)->setText(m_fileName);
411  }
412 
413 
418  m_startSamp = Null;
419  m_endSamp = Null;
420  m_startLine = Null;
421  m_endLine = Null;
422 
427  *m_incidenceAngle = Angle();
428 
430  }
431 
432 
437  int newRowPos = m_tableWin->table()->rowCount();
438  m_tableWin->table()->insertRow(newRowPos);
439  for (int c = 0; c < m_tableWin->table()->columnCount(); c++) {
440  QTableWidgetItem *item = new QTableWidgetItem("");
441  m_tableWin->table()->setItem(newRowPos, c, item);
442  }
443  m_tableWin->table()->scrollToItem(m_tableWin->table()->item(newRowPos, 0),
444  QAbstractItemView::PositionAtBottom);
445  }
446 
447 
453  try {
454  if (m_startSamp != Null && m_startLine != Null &&
455  m_endSamp != Null && m_endLine != Null) {
456  m_path = FileName(cubeViewport()->cube()->fileName()).path();
457  m_fileName = FileName(cubeViewport()->cube()->fileName()).name();
458 
459  /* |
460  * \ _ /
461  * -= (_) =- THE SUN
462  * / \ -
463  * | - <--- vector from the sun that intersects P1 and P2
464  * -
465  * -_ |
466  * /^\- |
467  * / | \ - |
468  * / H| \ - |
469  * ________/ | \__T_-|_________
470  * P1 ^ P2
471  * Shadow
472  *
473  * T: Angle from the horizon to the sun
474  * H: Difference in planetary radius between P1 and P2
475  * L : length(Shadow)
476  * H = L * tan(T)
477  *
478  * We do not want the local incidence angle for T.
479  *
480  * Equation to variable mapping:
481  * T: theta
482  * H: m_shadowHeight
483  * L: m_shadowLength
484  * P1: m_startSurfacePoint
485  * P2: m_endSurfacePoint
486  */
487 
488  bool success = true;
489  Camera *cam = cubeViewport()->cube()->camera();
490  success = cam->SetImage(m_startSamp, m_startLine);
491 
492  // Vector is in meters
493  QVector3D sunDirection;
494 
495  if (success) {
497  double sunPosition[3];
498  cam->sunPosition(sunPosition);
499 
500  Distance targetRadii[3];
501  cam->radii(targetRadii);
502 
503  double origin[3] = {0.0, 0.0, 0.0};
504  SpiceBoolean surfptSuccess;
505  // Vector is in kilometers
506  double naifVectorFromSunToP1[3] = {0.0, 0.0, 0.0};
507 
508  surfpt_c(origin, sunPosition, targetRadii[0].kilometers(),
509  targetRadii[1].kilometers(), targetRadii[2].kilometers(),
510  naifVectorFromSunToP1, &surfptSuccess);
511  success = surfptSuccess;
512 
513  if (success) {
514  sunDirection = QVector3D(
515  naifVectorFromSunToP1[0] * 1000.0,
516  naifVectorFromSunToP1[1] * 1000.0,
517  naifVectorFromSunToP1[2] * 1000.0).normalized();
518  }
519  }
520 
521  if (success) {
522  success = cam->SetImage(m_endSamp, m_endLine);
523  }
524 
525  if (success) {
527 
529  Angle theta = Angle(90.0, Angle::Degrees) - *m_incidenceAngle;
530 
531  Displacement deltaX = m_startSurfacePoint->GetX() - m_endSurfacePoint->GetX();
532 
533  Displacement deltaY = m_startSurfacePoint->GetY() - m_endSurfacePoint->GetY();
534 
535  Displacement deltaZ = m_startSurfacePoint->GetZ() - m_endSurfacePoint->GetZ();
536 
537  *m_shadowLength = Distance(sqrt( deltaX.meters() * deltaX.meters() +
538  deltaY.meters() * deltaY.meters() +
539  deltaZ.meters() * deltaZ.meters() ),
541 
542  *m_shadowHeight = Distance(m_shadowLength->meters() * tan( theta.radians() ),
544  }
545  }
546  }
547  catch (IException &) {
548  reinitialize();
549  }
550 
552  }
553 
554 
557  if (m_shadowHeight->isValid()) {
558  Distance::Units displayUnits =
559  (Distance::Units)m_unitsComboBox->itemData(
560  m_unitsComboBox->currentIndex()).toInt();
561 
562  switch (displayUnits) {
563  case Distance::Meters:
564  m_shadowHeightLineEdit->setText(
566  break;
568  m_shadowHeightLineEdit->setText(
570  break;
572  case Distance::Pixels:
573  m_shadowHeightLineEdit->setText("Not Supported");
574  break;
575  }
576 
577  }
578  else {
579  m_shadowHeightLineEdit->setText("");
580  }
581  }
582 
583 
589  MdiCubeViewport *activeViewport = cubeViewport();
590 
591  bool hasCamera = true;
592  try {
593  hasCamera = activeViewport &&
594  (activeViewport->cube()->camera() != NULL);
595  }
596  catch (IException &) {
597  hasCamera = false;
598  }
599 
600  m_shadowHeightLineEdit->setEnabled(hasCamera);
601  m_unitsComboBox->setEnabled(hasCamera);
602  m_enabled = hasCamera;
603 
605  }
606 
607 }
608 
This class defines a body-fixed surface point.
Definition: SurfacePoint.h:148
Cube display widget for certain Isis MDI applications.
QString path() const
Returns the path of the file name.
Definition: FileName.cpp:119
double meters() const
Get the distance in meters.
Definition: Distance.cpp:97
void recalculateShadowHeight()
Try to calculate the shadow height.
QString m_path
Current cube file path.
QString toolIconDir() const
returns the path to the icon directory.
Definition: Tool.h:127
const double Null
Value for an Isis Null pixel.
Definition: SpecialPixel.h:110
void setStatusMessage(QString message)
sets the status message in the lower lefthand corner of the window.
Cube * cube() const
Definition: CubeViewport.h:348
Distance * m_shadowHeight
Calculated shadow height.
bool m_enabled
True if this tool is enabled (capable of working). Requires a camera.
double SunAzimuth()
Returns the Sun Azimuth.
Definition: Camera.cpp:1939
File name manipulation and expansion.
Definition: FileName.h:116
Units
This is a list of available units to access and store Distances in.
Definition: Distance.h:54
double m_startLine
Start line of the measurement.
Shadow length in meters table column index.
Definition: SunShadowTool.h:99
Camera * camera()
Return a camera associated with the cube.
Definition: Cube.cpp:1166
Incidence angle in degrees table column index.
double radians() const
Convert an angle to a double.
Definition: Angle.h:243
Shadow height in meters table column index.
void reinitialize()
Clear all calculated values and then re-calculate them.
"Solar radius is a unit of distance used to express the size of stars in astronomy equal to the curre...
Definition: Distance.h:72
Angle * m_incidenceAngle
Incidence angle from the normal at the end point.
int toInt(const QString &string)
Global function to convert from a string to an integer.
Definition: IString.cpp:108
double m_startSamp
Start sample of the measurement.
double meters() const
Get the displacement in meters.
double m_endLine
End line of the measurement.
void updateShadowHeightEdit()
Change the value in the distance edit to match the units.
void sunPosition(double p[3]) const
Fills the input vector with sun position information, in either body-fixed or J2000 reference frame a...
Definition: Spice.cpp:827
virtual void mouseButtonPress(QPoint p, Qt::MouseButton s)
When the mouse left button is pressed we start tracking.
QString name() const
Returns the name of the file excluding the path and the attributes in the file name.
Definition: FileName.cpp:178
QComboBox * m_unitsComboBox
User can choose the height line edit&#39;s units (M or KM)
Definition: SunShadowTool.h:72
The distance is being specified in kilometers.
Definition: Distance.h:58
virtual void mouseButtonRelease(QPoint p, Qt::MouseButton s)
When the mouse left button is released we finish tracking.
QCheckBox * m_drawInSunDirection
Check box to enable/disable confining tracking to sun direction.
Definition: SunShadowTool.h:74
End lon table column index.
Definition: SunShadowTool.h:87
Cube file name table column index.
double m_endSamp
End sample of the measurement.
QString toString(bool boolToConvert)
Global function to convert a boolean to a string.
Definition: IString.cpp:226
void cubeToViewport(double sample, double line, int &x, int &y) const
Turns a cube into a viewport.
Unless noted otherwise, the portions of Isis written by the USGS are public domain.
void addTo(QMenu *menu)
Adds the measure action to the given menu.
double kilometers() const
Get the distance in kilometers.
Definition: Distance.cpp:118
QWidget * createToolBarWidget(QStackedWidget *parent)
Creates the widget (button) that goes on the tool bar.
Distance measurement, usually in meters.
Definition: Distance.h:47
Latitude GetLatitude() const
Return the body-fixed latitude for the surface point.
double degrees() const
Get the angle in units of Degrees.
Definition: Angle.h:249
End lat table column index.
Definition: SunShadowTool.h:85
void addRow()
Add a results row to the table.
QLineEdit * m_shadowHeightLineEdit
This displays the currently calculated height of the measured shadow.
Definition: SunShadowTool.h:70
Angle * m_trackingAngle
The angle that we want mouse tracking to be in.
Start lon table column index.
Definition: SunShadowTool.h:83
void setTrackListItems(bool track=false)
If this property is true, the class will keep track of the checked/unchecked items in the dock area w...
bool SetImage(const double sample, const double line)
Sets the sample/line values of the image to get the lat/lon values.
Definition: Camera.cpp:170
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 ...
Degrees are generally considered more human readable, 0-360 is one circle, however most math does not...
Definition: Angle.h:73
Start cube line table column index.
Definition: SunShadowTool.h:91
End cube sample table column index.
Definition: SunShadowTool.h:93
void updateTool()
This enables/disables this tool&#39;s functionality based on the active viewport&#39;s compatibility.
Start cube sample table column index.
Definition: SunShadowTool.h:89
Incidence angle in radians table column index.
End cube line table column index.
Definition: SunShadowTool.h:95
QAction * toolPadAction(ToolPad *pad)
Create an action for activating this tool.
bool isValid() const
Test if this distance has been initialized or not.
Definition: Distance.cpp:204
void paintViewport(MdiCubeViewport *vp, QPainter *painter)
Paint anything we need to on the viewport.
SurfacePoint * m_startSurfacePoint
Start ground coordinate of the measurement.
TableMainWindow * m_tableWin
Table window for displaying all of the table information.
Shadow length in kilometers table column index.
Definition: SunShadowTool.h:97
Start lat table column index.
Definition: SunShadowTool.h:81
void updateRow(int row)
This method updates the row in the table window with the current measure information.
QString m_fileName
Current cube file name.
a subclass of the qisis mainwindow, tablemainwindow handles all of the table tasks.
Shadow height in kilometers table column index.
Defines an angle and provides unit conversions.
Definition: Angle.h:62
Unless noted otherwise, the portions of Isis written by the USGS are public domain.
QTableWidget * table() const
Returns the table.
Longitude GetLongitude() const
Return the body-fixed longitude for the surface point.
Displacement is a signed length, usually in meters.
Definition: Displacement.h:43
Isis exception class.
Definition: IException.h:107
SurfacePoint GetSurfacePoint() const
Returns the surface point (most efficient accessor).
Definition: Sensor.cpp:270
SurfacePoint * m_endSurfacePoint
End ground coordinate of the measurement.
Namespace for ISIS/Bullet specific routines.
Definition: Apollo.h:31
Base class for the Qisis tools.
Definition: Tool.h:81
double IncidenceAngle() const
Returns the incidence angle in degrees.
Definition: Sensor.cpp:350
Distance * m_shadowLength
Calculated shadow length.
MdiCubeViewport * cubeViewport() const
Return the current cubeviewport.
Definition: Tool.h:211
The distance is being specified in meters.
Definition: Distance.h:56
bool m_tracking
True if currently tracking the user&#39;s mouse position and calculating values on every mouse move...
bool isValid() const
This indicates whether we have a legitimate angle stored or are in an unset, or invalid, state.
Definition: Angle.cpp:110
void addToTable(bool setOn, const QString &heading, const QString &menuText="", int insertAt=-1, Qt::Orientation o=Qt::Horizontal, QString toolTip="")
Adds a new column to the table when a new curve is added to the plot.
SunShadowTool(QWidget *parent)
Construct a sun shadow tool.
void radii(Distance r[3]) const
Returns the radii of the body in km.
Definition: Spice.cpp:855
void viewportToCube(int x, int y, double &sample, double &line) const
Turns a viewport into a cube.
Cube file path table column index.
The distance is being specified in pixels.
Definition: Distance.h:60
Unless noted otherwise, the portions of Isis written by the USGS are public domain.