Isis 3 Programmer Reference
ControlMeasureEditWidget.h
1 #ifndef ControlMeasureEditWidget_h
2 #define ControlMeasureEditWidget_h
3 
4 // This is the only include allowed in this file!
5 #include <QWidget>
6 
7 
8 class QCheckBox;
9 class QDial;
10 class QDoubleSpinBox;
11 class QHBoxLayout;
12 class QLabel;
13 class QLCDNumber;
14 class QListWidget;
15 class QPalette;
16 class QPushButton;
17 class QRadioButton;
18 class QScrollBar;
19 class QString;
20 class QTimer;
21 class QToolButton;
22 class QVBoxLayout;
23 
24 namespace Isis {
25  class AutoReg;
26  class Chip;
27  class ChipViewport;
28  class ControlMeasure;
29  class ControlNet;
30  class ControlPoint;
31  class Cube;
32  class CubeViewport;
33  class SerialNumberList;
34  class Stretch;
35  class Tool;
36  class UniversalGroundMap;
37 
167  Q_OBJECT
168 
169  public:
170  ControlMeasureEditWidget(QWidget *parent = 0, bool allowLeftMouse = false,
171  bool useGeometry = true);
178  QString templateFileName() {
179  return m_templateFileName;
180  };
181  void allowLeftMouse(bool allowMouse);
182 
183  void setLeftPosition(double sample, double line);
184  void setRightPosition(double sample, double line);
185 
186  signals:
187  void updateLeftView(double sample, double line);
188  void updateRightView(double sample, double line);
189  void measureSaved();
190  void newControlNetwork(ControlNet *);
191  void setTemplateFailed(QString);
192  void stretchChipViewport(Stretch *, CubeViewport *);
193 
194  public slots:
195  bool setTemplateFile(QString);
196  void setPoint(ControlPoint *editPoint, SerialNumberList *snList);
197  void setLeftMeasure(ControlMeasure *leftMeasure,
198  Cube *leftCube, QString pointId);
199  void setRightMeasure(ControlMeasure *rightMeasure,
200  Cube *rightCube, QString pointId);
201  void colorizeSaveButton();
202  void refreshChips();
203  void saveChips();
204 
205  protected slots:
206 
207  private slots:
208 
209  void setNoGeom();
210  void setGeom();
211  void setRotate();
212  void setCircle(bool);
213  void setZoomLink(bool);
214 
215  void findPoint();
216  void registerPoint();
217  void saveMeasure();
218  void updateLeftPositionLabel(double zoomFactor);
219  void updateRightGeom();
220  void updateRightPositionLabel(double zoomFactor);
221 
222  void blinkStart();
223  void blinkStop();
224  void changeBlinkTime(double interval);
225  void updateBlink();
226 
227  void showBlinkExtension();
228  void blinkStartRight();
229  void blinkStopRight();
230  void changeBlinkTimeRight(double interval);
231  void updateBlinkRight();
232 
233 
234  private:
235  void createMeasureEditor(QWidget *parent);
236 
239 
247  QRadioButton *m_nogeom;
248  QRadioButton *m_geom;
249  QToolButton *m_rightZoomIn;
250  QToolButton *m_rightZoomOut;
251  QToolButton *m_rightZoom1;
252 
253  bool m_timerOn;
254  QTimer *m_timer;
256  unsigned char m_blinkIndex;
257 
258  QDial *m_dial;
259  QLCDNumber *m_dialNumber;
260  QDoubleSpinBox *m_blinkTimeBox;
261 
262  bool m_circle;
263  QScrollBar *m_slider;
264 
265  QPushButton *m_autoReg;
267  QLabel *m_oldPosition;
268  QLabel *m_goodFit;
271 
272  QPushButton *m_saveMeasure;
274 
277 
286 
288  QString m_pointId;
289 
291  bool m_geomIt;
292  bool m_linkZoom;
293 
294 
295 
299  QListWidget *m_blinkListWidget;
300 
301 
302  QDoubleSpinBox *m_blinkTimeBoxRight;
304  QTimer *m_timerRight;
306  unsigned char m_blinkIndexRight;
307 
308  };
309 };
310 
311 #endif
ControlPoint * m_editPoint
The control point currently being edited.
void setLeftPosition(double sample, double line)
Set the tack position of the measure in the left ChipViewport.
SerialNumberList * m_serialNumberList
The serial numbers for each measure of m_editpoint.
void blinkStartRight()
Slot to start blink function for advanced blink functionality.
Universal Ground Map.
void setCircle(bool)
Turn circle widgets on/off.
void updateBlinkRight()
Slot to cause the blink to happen coinciding with the timer.
QLabel * m_rightSampLinePosition
Label for right chip viewport&#39;s current sample/line.
void blinkStart()
Slot to start blink function.
QListWidget * m_blinkListWidget
List of images being blinked through.
QDoubleSpinBox * m_blinkTimeBoxRight
Input for time between image blinks.
A small chip of data used for pattern matching.
Definition: Chip.h:102
void updateRightPositionLabel(double zoomFactor)
Update sample/line, lat/lon and zoom factor of right measure.
QTimer * m_timer
Timer on the blinking.
QLabel * m_leftZoomFactor
Label for left chip viewport&#39;s zoom factor.
QPushButton * m_autoReg
Button to auto-register the measure.
bool m_linkZoom
Link zoom factors between chip viewports.
ChipViewport * m_leftView
Left ChipViewport.
Widget to display Isis cubes for qt apps.
Definition: CubeViewport.h:132
ControlMeasureEditWidget(QWidget *parent=0, bool allowLeftMouse=false, bool useGeometry=true)
Constructs a ControlMeasureEditWidget widget.
void setNoGeom()
Slot to turn off geom.
QLabel * m_rightZoomFactor
Label for right chip viewport&#39;s zoom factor.
void changeBlinkTime(double interval)
Set blink rate.
void colorizeSaveButton()
Turn "Save Measure" button text to red.
bool m_circle
Whether or not to draw circle in center of the right chip viewport.
bool m_timerOnRight
Timer is on for right viewport.
bool m_useGeometry
Whether or not to allow geometry/rotation on right chip viewport.
QLCDNumber * m_dialNumber
The current amount of rotation (in degrees)
void setPoint(ControlPoint *editPoint, SerialNumberList *snList)
Set the Control Point for this widget.
void saveChips()
Slot to save registration chips to files and fire off qview.
void updateBlink()
Slot to cause the blink to happen coinciding with the timer.
void updateLeftPositionLabel(double zoomFactor)
Update sample/line, lat/lon and zoom factor of left measure.
UniversalGroundMap * m_leftGroundMap
UniversalGroundMap for left cube.
QWidget * m_blinkExtension
Widget for selecting images and timing to blink through them.
void saveMeasure()
Save control measure under the crosshair in right ChipViewport.
void setRotate()
Slot to update the right ChipViewport for zoom operations.
void findPoint()
Find point from left ChipViewport in the right ChipViewport.
a control network
Definition: ControlNet.h:271
bool m_geomIt
Apply geometry to the right chip viewport.
void blinkStop()
Slot to stop blink function.
Pixel value mapper.
Definition: Stretch.h:72
unsigned char m_blinkIndexRight
Index of image being blinked.
void setRightPosition(double sample, double line)
Set the tack position of the measure in the right ChipViewport.
void changeBlinkTimeRight(double interval)
Set blink rate.
QScrollBar * m_slider
Slider that controls the size of the center circle.
QString templateFileName()
Returns the template filename used for auto-registration.
AutoReg * m_autoRegFact
Created AutoReg.
bool m_allowLeftMouse
Whether or not to allow mouse events on left chip viewport.
A single control point.
Definition: ControlPoint.h:369
QTimer * m_timerRight
Timer for tracking image blink time.
QLabel * m_rightLatLonPosition
Label for right chip viewport&#39;s current lat/lon.
QRadioButton * m_geom
Radio button to apply geometry/rotation to right chip viewport.
bool m_autoRegAttempted
Whether or not auto-registration has been attempted.
void setLeftMeasure(ControlMeasure *leftMeasure, Cube *leftCube, QString pointId)
Set the measure displayed in the left ChipViewport.
QRadioButton * m_nogeom
Radio button to remove geometry/rotation for right chip viewport.
ControlMeasure * m_rightMeasure
Right ControlMeasure.
void setRightMeasure(ControlMeasure *rightMeasure, Cube *rightCube, QString pointId)
Set the measure displayed in the right ChipViewport.
QString m_templateFileName
Registration template filename.
QLabel * m_goodFit
The goodness of fit value after registering.
QToolButton * m_rightZoomOut
Button for zooming out right chip viewport.
void createMeasureEditor(QWidget *parent)
Design the MeasureEdit widget.
Auto Registration class.
Definition: AutoReg.h:183
int m_rotation
Amount to rotate right chip viewport TODO Is this used??
QToolButton * m_rightZoomIn
Button for zooming in right chip viewport.
Viewport for Isis Chips.
Definition: ChipViewport.h:85
void registerPoint()
Sub-pixel register point in right chipViewport with point in left.
Cube * m_leftCube
Left chip viewport&#39;s Cube.
QDoubleSpinBox * m_blinkTimeBox
The current blink step (in seconds)
ChipViewport * m_rightView
Right ChipViewport.
ControlMeasure * m_leftMeasure
Left ControlMeasure.
QLabel * m_oldPosition
The old sample and line before registering.
QPalette m_saveDefaultPalette
Default color palette for the Save button.
Namespace for ISIS/Bullet specific routines.
Definition: Apollo.h:31
QList< ChipViewport * > m_blinkList
List of chip viewports to blink.
void updateRightGeom()
Slot to update the geomed right ChipViewport for zoom operations.
a control measurement
bool m_timerOn
Indicates if the blink timer is on.
QString m_pointId
Associated control point id of the right measure.
QPushButton * m_saveMeasure
Button to save the current measure.
bool m_autoRegShown
Whether or not the auto-reg extension is shown.
QLabel * m_leftLatLonPosition
Label for left chip viewport&#39;s current lat/lon.
Cube * m_rightCube
Right chip viewport&#39;s Cube.
QToolButton * m_rightZoom1
Button for 1:1 zoom on right chip viewport.
QLabel * m_leftSampLinePosition
Label for left chip viewport&#39;s current sample/line.
Serial Number list generator.
QWidget * m_autoRegExtension
Widget that shows after registering a measure.
void allowLeftMouse(bool allowMouse)
Set the option that allows mouse movements in the left ChipViewport.
unsigned char m_blinkIndex
Index of the chip to load in the left chip viewport.
UniversalGroundMap * m_rightGroundMap
UniversalGroundMap for right cube.
QList< ChipViewport * > m_blinkChipViewportListRight
List of viewports to blink through.
bool setTemplateFile(QString)
Allows user to choose a new template file by opening a window from which to select a filename...
void setZoomLink(bool)
Turn linking of zoom on or off.
void blinkStopRight()
Slot to stop blink function.
IO Handler for Isis Cubes.
Definition: Cube.h:170