1 #include "ControlMeasureEditWidget.h" 3 #include <QApplication> 4 #include <QButtonGroup> 8 #include <QDoubleSpinBox> 10 #include <QGridLayout> 11 #include <QHBoxLayout> 13 #include <QListWidget> 14 #include <QMessageBox> 16 #include <QPushButton> 17 #include <QRadioButton> 22 #include <QToolButton> 58 bool useGeometry) :
QWidget(parent) {
115 QGridLayout *gridLayout =
new QGridLayout();
116 gridLayout->setSizeConstraint(QLayout::SetFixedSize);
121 QString toolIconDir = tempFileName;
125 QToolButton *leftZoomIn =
new QToolButton();
126 leftZoomIn->setIcon(QPixmap(toolIconDir +
"/viewmag+.png"));
127 leftZoomIn->setIconSize(isize);
128 leftZoomIn->setToolTip(
"Zoom In 2x");
129 leftZoomIn->setWhatsThis(
"Zoom In 2x on left measure.");
131 QToolButton *leftZoomOut =
new QToolButton();
132 leftZoomOut->setIcon(QPixmap(toolIconDir +
"/viewmag-.png"));
133 leftZoomOut->setIconSize(isize);
134 leftZoomOut->setToolTip(
"Zoom Out 2x");
135 leftZoomOut->setWhatsThis(
"Zoom Out 2x on left measure.");
137 QToolButton *leftZoom1 =
new QToolButton();
138 leftZoom1->setIcon(QPixmap(toolIconDir +
"/viewmag1.png"));
139 leftZoom1->setIconSize(isize);
140 leftZoom1->setToolTip(
"Zoom 1:1");
141 leftZoom1->setWhatsThis(
"Show left measure at full resolution.");
143 QHBoxLayout *leftZoomPan =
new QHBoxLayout;
144 leftZoomPan->addWidget(leftZoomIn);
145 leftZoomPan->addWidget(leftZoomOut);
146 leftZoomPan->addWidget(leftZoom1);
149 QToolButton *leftPanUp = 0;
150 QToolButton *leftPanDown = 0;
151 QToolButton *leftPanLeft = 0;
152 QToolButton *leftPanRight = 0;
155 leftPanUp =
new QToolButton(parent);
156 leftPanUp->setIcon(QIcon(
FileName(
"$base/icons/up.png").
158 leftPanUp->setIconSize(isize);
159 leftPanUp->setToolTip(
"Move up 1 screen pixel");
160 leftPanUp->setStatusTip(
"Move up 1 screen pixel");
161 leftPanUp->setWhatsThis(
"Move the left measure up 1 screen pixel.");
163 leftPanDown =
new QToolButton(parent);
164 leftPanDown->setIcon(QIcon(
FileName(
"$base/icons/down.png").
166 leftPanDown->setIconSize(isize);
167 leftPanDown->setToolTip(
"Move down 1 screen pixel");
168 leftPanDown->setStatusTip(
"Move down 1 screen pixel");
169 leftPanDown->setWhatsThis(
"Move the left measure down 1 screen pixel.");
171 leftPanLeft =
new QToolButton(parent);
172 leftPanLeft->setIcon(QIcon(
FileName(
"$base/icons/back.png").
174 leftPanLeft->setIconSize(isize);
175 leftPanLeft->setToolTip(
"Move left 1 screen pixel");
176 leftPanLeft->setWhatsThis(
"Move the left measure to the left by 1 screen" 179 leftPanRight =
new QToolButton(parent);
180 leftPanRight->setIcon(QIcon(
FileName(
"$base/icons/forward.png").
182 leftPanRight->setIconSize(isize);
183 leftPanRight->setToolTip(
"Move right 1 screen pixel");
184 leftPanRight->setWhatsThis(
"Move the left measure to the right by 1" 187 leftZoomPan->addWidget(leftPanUp);
188 leftZoomPan->addWidget(leftPanDown);
189 leftZoomPan->addWidget(leftPanLeft);
190 leftZoomPan->addWidget(leftPanRight);
193 leftZoomPan->addStretch();
194 gridLayout->addLayout(leftZoomPan, row, 0);
197 m_rightZoomIn->setIcon(QPixmap(toolIconDir +
"/viewmag+.png"));
210 m_rightZoom1->setIcon(QPixmap(toolIconDir +
"/viewmag1.png"));
213 m_rightZoom1->setWhatsThis(
"Show right measure at full resolution.");
215 QHBoxLayout *rightZoomPan =
new QHBoxLayout;
221 QToolButton *rightPanUp =
new QToolButton(parent);
222 rightPanUp->setIcon(QIcon(
FileName(
"$base/icons/up.png").
224 rightPanUp->setIconSize(isize);
225 rightPanUp->setToolTip(
"Move up 1 screen pixel");
226 rightPanUp->setWhatsThis(
"Move the right measure up 1 screen pixel.");
228 QToolButton *rightPanDown =
new QToolButton(parent);
229 rightPanDown->setIcon(QIcon(
FileName(
"$base/icons/down.png").
231 rightPanDown->setIconSize(isize);
232 rightPanDown->setToolTip(
"Move down 1 screen pixel");
233 rightPanUp->setWhatsThis(
"Move the right measure down 1 screen pixel.");
235 QToolButton *rightPanLeft =
new QToolButton(parent);
236 rightPanLeft->setIcon(QIcon(
FileName(
"$base/icons/back.png").
238 rightPanLeft->setIconSize(isize);
239 rightPanLeft->setToolTip(
"Move left 1 screen pixel");
240 rightPanLeft->setWhatsThis(
"Move the right measure to the left by 1 screen" 243 QToolButton *rightPanRight =
new QToolButton(parent);
244 rightPanRight->setIcon(QIcon(
FileName(
"$base/icons/forward.png").
246 rightPanRight->setIconSize(isize);
247 rightPanRight->setToolTip(
"Move right 1 screen pixel");
248 rightPanRight->setWhatsThis(
"Move the right measure to the right by 1" 251 rightZoomPan->addWidget(rightPanUp);
252 rightZoomPan->addWidget(rightPanDown);
253 rightZoomPan->addWidget(rightPanLeft);
254 rightZoomPan->addWidget(rightPanRight);
255 rightZoomPan->addStretch();
257 gridLayout->addLayout(rightZoomPan, row++, 1);
261 QCheckBox *leftLockStretch =
new QCheckBox(
"lock stretch");
264 QString whatsThisTextForStretchLocking =
"If checked then a new stretch " 265 "will NOT be calculated for each pan or zoom change. Note that stretch" 266 " changes made using the stretch tool will ALWAYS take effect, " 267 "regardless of the state of this checkbox.";
268 leftLockStretch->setWhatsThis(whatsThisTextForStretchLocking);
269 QHBoxLayout *leftzflsLayout =
new QHBoxLayout;
271 leftzflsLayout->addWidget(leftLockStretch);
272 gridLayout->addLayout(leftzflsLayout, row, 0);
275 QCheckBox *rightLockStretch =
new QCheckBox(
"lock stretch");
276 rightLockStretch->setWhatsThis(whatsThisTextForStretchLocking);
277 QHBoxLayout *rightzflsLayout =
new QHBoxLayout;
279 rightzflsLayout->addWidget(rightLockStretch);
280 gridLayout->addLayout(rightzflsLayout, row++, 1);
289 connect(
this, SIGNAL(newControlNetwork(
ControlNet *)),
297 connect(leftLockStretch, SIGNAL(stateChanged(
int)),
299 SLOT(changeStretchLock(
int)));
300 leftLockStretch->setChecked(
false);
304 connect(leftZoomIn, SIGNAL(clicked()),
m_leftView, SLOT(zoomIn()));
305 connect(leftZoomOut, SIGNAL(clicked()),
m_leftView, SLOT(zoomOut()));
306 connect(leftZoom1, SIGNAL(clicked()),
m_leftView, SLOT(zoom1()));
310 connect(leftZoomOut, SIGNAL(clicked()),
this, SLOT(
updateRightGeom()));
315 connect(
m_leftView, SIGNAL(tackPointChanged(
double)),
320 connect(
this, SIGNAL(updateLeftView(
double,
double)),
321 m_leftView, SLOT(refreshView(
double,
double)));
323 connect (
m_leftView, SIGNAL(userMovedTackPoint()),
328 connect(leftPanUp, SIGNAL(clicked()),
m_leftView, SLOT(panUp()));
329 connect(leftPanDown, SIGNAL(clicked()),
m_leftView, SLOT(panDown()));
330 connect(leftPanLeft, SIGNAL(clicked()),
m_leftView, SLOT(panLeft()));
331 connect(leftPanRight, SIGNAL(clicked()),
m_leftView, SLOT(panRight()));
342 connect(
this, SIGNAL(newControlNetwork(
ControlNet *)),
346 connect(rightLockStretch, SIGNAL(stateChanged(
int)),
348 rightLockStretch->setChecked(
false);
352 connect(
m_rightView, SIGNAL(tackPointChanged(
double)),
354 connect(
this, SIGNAL(updateRightView(
double,
double)),
357 connect (
m_rightView, SIGNAL(userMovedTackPoint()),
365 connect(rightPanUp, SIGNAL(clicked()),
m_rightView, SLOT(panUp()));
366 connect(rightPanDown, SIGNAL(clicked()),
m_rightView, SLOT(panDown()));
367 connect(rightPanLeft, SIGNAL(clicked()),
m_rightView, SLOT(panLeft()));
368 connect(rightPanRight, SIGNAL(clicked()),
m_rightView, SLOT(panRight()));
379 QButtonGroup *bgroup =
new QButtonGroup();
384 QCheckBox *linkZoom = NULL;
386 m_nogeom->setText(
"No geom/rotate");
387 m_nogeom->setToolTip(
"Reset right measure to it's native geometry.");
388 m_nogeom->setWhatsThis(
"Reset right measure to it's native geometry. " 389 "If measure was rotated, set rotation back to 0. " 390 "If measure was geomed to match the left measure, " 391 "reset the geometry back to it's native state.");
392 m_geom =
new QRadioButton(
"Geom");
393 m_geom->setToolTip(
"Geom right measure to match geometry of left measure.");
394 m_geom->setWhatsThis(
"Using an affine transform, geom the right measure to match the " 395 "geometry of the left measure.");
396 bgroup->addButton(
m_geom);
400 linkZoom =
new QCheckBox(
"Link Zoom");
401 linkZoom->setToolTip(
"Link zooming between the left and right views.");
402 linkZoom->setWhatsThis(
"When zooming in the left view, the right view will " 403 "be set to the same zoom factor as the left view.");
404 connect(linkZoom, SIGNAL(toggled(
bool)),
this, SLOT(
setZoomLink(
bool)));
407 m_nogeom->setToolTip(
"Reset right measure to it's native geometry.");
408 m_nogeom->setWhatsThis(
"Reset right measure to it's native geometry. " 409 "If measure was rotated, set rotation back to 0.");
413 QRadioButton *rotate =
new QRadioButton(
"Rotate");
414 bgroup->addButton(rotate);
416 connect(rotate, SIGNAL(clicked()),
this, SLOT(
setRotate()));
425 m_dial->setWrapping(
false);
426 m_dial->setNotchesVisible(
true);
427 m_dial->setNotchTarget(5.);
428 m_dial->setEnabled(
false);
429 m_dial->setToolTip(
"Rotate right measure");
430 m_dial->setWhatsThis(
"Rotate the right measure by degrees.");
435 m_dialNumber->setWhatsThis(
"Rotate the right measure by given number" 440 QCheckBox *showPoints =
new QCheckBox(
"Show control points");
441 showPoints->setToolTip(
"Draw control point crosshairs");
442 showPoints->setWhatsThis(
"This will toggle whether crosshairs are drawn" 443 " for the control points located within the measure''s" 444 " view. For areas of dense measurements, turning this" 445 " off will allow easier viewing of features.");
446 connect(showPoints, SIGNAL(toggled(
bool)),
m_leftView, SLOT(setPoints(
bool)));
447 connect(showPoints, SIGNAL(toggled(
bool)),
m_rightView, SLOT(setPoints(
bool)));
448 showPoints->setChecked(
true);
450 QCheckBox *cross =
new QCheckBox(
"Show crosshair");
451 connect(cross, SIGNAL(toggled(
bool)),
m_leftView, SLOT(setCross(
bool)));
452 connect(cross, SIGNAL(toggled(
bool)),
m_rightView, SLOT(setCross(
bool)));
453 cross->setChecked(
true);
454 cross->setToolTip(
"Show the red crosshair across measure view");
455 cross->setWhatsThis(
"This will toggle whether the crosshair across the" 456 " measure view will be shown");
458 QCheckBox *circle =
new QCheckBox(
"Circle");
459 circle->setChecked(
false);
460 circle->setToolTip(
"Draw circle");
461 circle->setWhatsThis(
"Draw circle on measure view. This can aid in" 462 " centering a crater under the crosshair.");
463 connect(circle, SIGNAL(toggled(
bool)),
this, SLOT(
setCircle(
bool)));
465 m_slider =
new QScrollBar(Qt::Horizontal);
473 m_slider->setToolTip(
"Adjust circle size");
474 m_slider->setWhatsThis(
"This allows the cirle size to be adjusted.");
476 QVBoxLayout *vlayout =
new QVBoxLayout();
478 vlayout->addWidget(linkZoom);
482 vlayout->addWidget(
m_geom);
484 vlayout->addWidget(rotate);
485 vlayout->addWidget(
m_dial);
487 vlayout->addWidget(showPoints);
488 vlayout->addWidget(cross);
489 vlayout->addWidget(circle);
491 gridLayout->addLayout(vlayout, row++, 2);
514 m_oldPosition->setToolTip(
"Measure Sample/Line before sub-pixel " 516 m_oldPosition->setWhatsThis(
"Original Sample/Line of the right measure " 517 "before the sub-pixel registration. If you select the \"Undo\" " 518 "button, the measure will revert back to this Sample/Line.");
520 m_goodFit->setToolTip(
"Goodness of Fit result from sub-pixel registration.");
521 m_goodFit->setWhatsThis(
"Resulting Goodness of Fit from sub-pixel " 523 QVBoxLayout *autoRegLayout =
new QVBoxLayout;
524 autoRegLayout->setMargin(0);
533 QHBoxLayout *leftLayout =
new QHBoxLayout();
534 QToolButton *stop =
new QToolButton();
535 stop->setIcon(QPixmap(toolIconDir +
"/blinkStop.png"));
536 stop->setIconSize(QSize(22, 22));
537 stop->setToolTip(
"Blink Stop");
538 QString text =
"<b>Function:</b> Stop automatic timed blinking";
539 stop->setWhatsThis(text);
540 connect(stop, SIGNAL(released()),
this, SLOT(
blinkStop()));
542 QToolButton *start =
new QToolButton();
543 start->setIcon(QPixmap(toolIconDir +
"/blinkStart.png"));
544 start->setIconSize(QSize(22, 22));
545 start->setToolTip(
"Blink Start");
546 text =
"<b>Function:</b> Start automatic timed blinking. Cycles \ 547 through linked viewports at variable rate";
548 start->setWhatsThis(text);
549 connect(start, SIGNAL(released()),
this, SLOT(
blinkStart()));
558 text =
"<b>Function:</b> Change automatic blink rate between " +
565 leftLayout->addWidget(stop);
566 leftLayout->addWidget(start);
570 QPushButton *find =
new QPushButton(
"Find");
571 find->setShortcut(Qt::Key_F);
572 find->setToolTip(
"Move right measure to same Latitude/Longitude as left. " 573 "<strong>Shortcut: F</strong>");
574 find->setWhatsThis(
"Find the Latitude/Longitude under the crosshair in the " 575 "left measure and move the right measure to the same " 576 "latitude/longitude.");
577 leftLayout->addWidget(find);
578 connect(find, SIGNAL(clicked()),
this, SLOT(
findPoint()));
581 leftLayout->addStretch();
582 gridLayout->addLayout(leftLayout, row, 0);
584 QHBoxLayout *rightLayout =
new QHBoxLayout();
587 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left. " 588 "<strong>Shortcut: R</strong>");
589 m_autoReg->setWhatsThis(
"Sub-pixel register the right measure to the left " 590 "and move the result under the crosshair. After " 591 "viewing the results, the option exists to move the " 592 "measure back to the original position by selecting " 593 "<strong>\"Undo Registration\"</strong>.");
596 m_saveMeasure->setToolTip(
"Save the both the left and right measure to the edit control " 597 "point (control point currently being edited). " 598 "<strong>Shortcut: M</strong>. " 599 " <strong>Note: The edit control point " 600 "will not be saved to the network until you select " 601 "<strong>\"Save Point\"</strong>");
605 m_saveMeasure->setToolTip(
"Save the right measure to the edit control " 606 "point (control point currently being edited). " 607 "<strong>Shortcut: M</strong>. " 608 " <strong>Note: The edit control point " 609 "will not be saved to the network until you select " 610 "<strong>\"Save Point\"</strong>");
619 QPushButton *blinkButton =
new QPushButton(
"Advanced Blink");
620 blinkButton->setCheckable(
true);
621 connect(blinkButton, &QAbstractButton::toggled,
m_blinkExtension, &QWidget::setVisible);
622 connect(blinkButton, SIGNAL(clicked()),
this, SLOT(showBlinkExtension()));
624 QHBoxLayout *rightBlinkLayout =
new QHBoxLayout();
625 QToolButton *stopRight =
new QToolButton();
626 stopRight->setIcon(QPixmap(toolIconDir +
"/blinkStop.png"));
627 stopRight->setIconSize(QSize(22, 22));
628 stopRight->setToolTip(
"Blink Stop");
629 text =
"<b>Function:</b> Stop automatic timed blinking";
630 stopRight->setWhatsThis(text);
631 connect(stopRight, SIGNAL(released()),
this, SLOT(
blinkStopRight()));
633 QToolButton *startRight =
new QToolButton();
634 startRight->setIcon(QPixmap(toolIconDir +
"/blinkStart.png"));
635 startRight->setIconSize(QSize(22, 22));
636 startRight->setToolTip(
"Blink Start");
637 text =
"<b>Function:</b> Start automatic timed blinking. Cycles \ 638 through linked viewports at variable rate";
639 startRight->setWhatsThis(text);
640 connect(startRight, SIGNAL(released()),
this, SLOT(
blinkStartRight()));
649 text =
"<b>Function:</b> Change automatic blink rate between " +
656 rightBlinkLayout->addWidget(stopRight);
657 rightBlinkLayout->addWidget(startRight);
683 rightLayout->addWidget(blinkButton);
684 rightLayout->addStretch();
685 gridLayout->addLayout(rightLayout, row++, 1);
690 setLayout(gridLayout);
724 Cube *leftCube, QString pointId) {
732 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left." 733 "<strong>Shortcut: R</strong>");
769 emit updateLeftView(sample, line);
783 emit updateRightView(sample, line);
814 Cube *rightCube, QString pointId) {
823 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left. " 824 "<strong>Shortcut: R</strong>");
850 QString message = fullError.
toString();
851 QMessageBox::information((
QWidget *)parent(),
"Error", message);
855 m_geom->setChecked(
false);
893 pos =
"Latitude: " + QString::number(lat) +
894 " Longitude: " + QString::number(lon);
899 pos =
"Zoom Factor: " + QString::number(zoomFactor);
927 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left. " 928 "<strong>Shortcut: R</strong>");
942 pos =
"Latitude: " + QString::number(lat) +
943 " Longitude: " + QString::number(lon);
948 pos =
"Zoom Factor: " + QString::number(zoomFactor);
963 p.setColor(QPalette::ButtonText,qc);
995 QString message =
"Latitude: " + QString::number(lat) +
" Longitude: " +
996 QString::number(lon) +
" is not on the right image. Right measure " +
998 QMessageBox::warning((
QWidget *)parent(),
"Warning",message);
1044 "Cannot create AutoRegFactory. As a result, " 1045 "sub-pixel registration will not work.",
1047 QString message = fullError.
toString();
1048 QMessageBox::information((
QWidget *)parent(),
"Error", message);
1059 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left. " 1060 "<strong>Shortcut: R</strong>");
1088 QString msg =
"Cannot register this point, unable to Load chips.\n";
1090 QMessageBox::information((
QWidget *)parent(),
"Error", msg);
1097 QString msg =
"Cannot sub-pixel register this point.\n";
1099 msg +=
"\n\nNot enough valid data in Pattern Chip.\n";
1100 msg +=
" PatternValidPercent = ";
1104 msg +=
"\n\nNo valid data in Fit Chip.";
1107 msg +=
"\n\nGoodness of Fit Tolerance not met.\n";
1109 msg +=
"\nGoodnessOfFitTolerance = ";
1113 msg +=
"\n\nNot enough valid points in the fit chip window for sub-pixel ";
1114 msg +=
"accuracy. Probably too close to edge.\n";
1117 msg +=
"\n\nCould not model surface for sub-pixel accuracy.\n";
1120 double sampDist, lineDist;
1122 msg +=
"\n\nSub pixel algorithm moves registration more than tolerance.\n";
1123 msg +=
"\nSampleMovement = " + QString::number(sampDist) +
1124 " LineMovement = " + QString::number(lineDist);
1125 msg +=
"\nDistanceTolerance = " +
1129 double score1, score2;
1131 msg +=
"\n\nPattern data max or min does not pass z-score test.\n";
1133 msg +=
"\nCalculatedZscores = " + QString::number(score1) +
", " + QString::number(score2);
1136 msg +=
"\n\nError occured in Adaptive algorithm.";
1139 msg +=
"\n\nUnknown registration error.";
1142 QMessageBox::information((
QWidget *)parent(),
"Error", msg);
1147 QString msg =
"Cannot register this point.\n";
1149 QMessageBox::information((
QWidget *)parent(),
"Error", msg);
1163 QString oldPos =
"Original Sample: " +
1164 QString::number(
m_rightMeasure->GetSample()) +
" Original Line: " +
1168 QString goodFit =
"Goodness of Fit: " +
1174 m_autoReg->setText(
"Undo Registration");
1175 m_autoReg->setToolTip(
"Undo sub-pixel registration. " 1176 "<strong>Shortcut: U</strong>");
1223 QString message =
"The right measure is locked. You must first unlock the measure by ";
1224 message +=
"clicking the check box above labeled \"Edit Lock Measure\".";
1225 QMessageBox::warning((
QWidget *)parent(),
"Warning",message);
1236 double minZScore, maxZScore;
1249 QMessageBox::critical((
QWidget *)parent(),
"Error", message);
1264 m_autoReg->setToolTip(
"Sub-pixel register the right measure to the left. " 1265 "<strong>Shortcut: R</strong>");
1289 QString message =
"The left measure is locked. You must first unlock the measure by ";
1290 message +=
"clicking the check box above labeled \"Edit Lock Measure\".";
1291 QMessageBox::warning((
QWidget *)parent(),
"Warning",message);
1315 emit measureSaved();
1336 QString message = fullError.
toString();
1337 QMessageBox::information((
QWidget *)parent(),
"Error", message);
1340 m_geom->setChecked(
false);
1381 QApplication::setOverrideCursor(Qt::WaitCursor);
1385 QString text =
"Zoom in 2X";
1389 text =
"Zoom out 2X";
1401 QApplication::restoreOverrideCursor();
1403 m_dial->setEnabled(
true);
1405 m_dial->setNotchesVisible(
true);
1423 QApplication::setOverrideCursor(Qt::WaitCursor);
1426 QString text =
"Zoom functions disabled when Geom is set";
1440 m_dial->setEnabled(
false);
1451 QString message = fullError.
toString();
1452 QMessageBox::information((
QWidget *)parent(),
"Error", message);
1455 m_geom->setChecked(
false);
1458 QApplication::restoreOverrideCursor();
1470 QApplication::setOverrideCursor(Qt::WaitCursor);
1472 QString text =
"Zoom in 2X";
1476 text =
"Zoom out 2X";
1487 m_dial->setEnabled(
false);
1493 QApplication::restoreOverrideCursor();
1641 "Cannot create AutoRegFactory for " +
1643 ". As a result, current template file will remain set to " +
1645 QString message = fullError.
toString();
1646 QMessageBox::information((
QWidget *)parent(),
"Error", message);
1665 m_saveMeasure->setToolTip(
"Save the both the left and right measure to the edit control " 1666 "point (control point currently being edited). " 1667 " <strong>Note: The edit control point " 1668 "will not be saved to the network until you select " 1669 "<strong>\"Save Point\"</strong>");
1673 m_saveMeasure->setToolTip(
"Save the right measure to the edit control " 1674 "point (control point currently being edited). " 1675 " <strong>Note: The edit control point " 1676 "will not be saved to the network until you select " 1677 "<strong>\"Save Point\"</strong>");
1682 void ControlMeasureEditWidget::refreshChips() {
1701 QString message =
"Point must be Registered before chips can be saved.";
1702 QMessageBox::warning((
QWidget *)parent(),
"Warning", message);
1707 QString baseFile =
m_pointId.replace(
" ",
"_") +
"_" +
1712 QString fname = baseFile +
"Search.cub";
1713 QString command =
"$ISISROOT/bin/qview \'" + fname +
"\'";
1715 fname = baseFile +
"Pattern.cub";
1716 command +=
" \'" + fname +
"\'";
1718 fname = baseFile +
"Fit.cub";
1719 command +=
" \'" + fname +
"\' &";
1742 void ControlMeasureEditWidget::showBlinkExtension() {
1745 for (
int i=0; i<
m_editPoint->GetNumMeasures(); i++) {
1771 if (selected.size() < 1) {
1772 QMessageBox::information((
QWidget *)parent(),
"Error",
"No files selected for blinking.");
1777 for (
int i=0; i<selected.size(); i++) {
1778 QString file = selected.at(i)->text();
1780 Cube *blinkCube =
new Cube(selected.at(i)->text());
1783 blinkChip->TackCube(blinkMeasure->GetSample(), blinkMeasure->GetLine());
1784 blinkChip->Load(*blinkCube);
1786 blinkViewport->
setChip(blinkChip, blinkCube);
Status SetType(MeasureType type)
Set how the coordinate was obtained.
Error occured in Adaptive algorithm.
double MinimumZScore() const
Return minimumPatternZScore.
void zoom(double zoomFactor)
Zoom by a specified factor.
double Line() const
Returns the current line value of the camera model or projection.
File name manipulation and expansion.
const ControlMeasure * GetMeasure(QString serialNumber) const
Get a control measure based on its cube's serial number.
A small chip of data used for pattern matching.
Chip * RegistrationSearchChip()
Return pointer to search chip used in registration.
Not enough valid data in pattern chip.
Not enough points to fit a surface model for sub-pixel accuracy.
QString serialNumber(const QString &filename)
Return a serial number given a filename.
Chip * RegistrationPatternChip()
Return pointer to pattern chip used in registration.
Surface model moves registration more than one pixel.
Statistical and similar ControlMeasure associated information.
double DistanceTolerance() const
Return distance tolerance.
void TackCube(const double cubeSample, const double cubeLine)
This sets which cube position will be located at the chip tack position.
AutoReg::RegisterStatus Register()
Walk the pattern chip through the search chip to find the best registration.
Chip * SearchChip()
Return pointer to search chip.
QString toString(bool boolToConvert)
Global function to convert a boolean to a string.
Widget to display Isis cubes for qt apps.
Registered to sub-pixel (e.g., pointreg)
double GoodnessOfFit() const
Return the goodness of fit of the match algorithm.
A type of error that occurred when performing an actual I/O operation.
double tackLine()
Returns tack line.
double tackSample()
Return the position of cube under cross hair.
Control measures store z-scores in pairs.
double CubeSample() const
Return the search chip cube sample that best matched.
QString fileName(const QString &sn)
Return a filename given a serial number.
void ZScores(double &score1, double &score2) const
Return the ZScores of the pattern chip.
static void RunSystemCommand(QString commandLine)
This runs arbitrary system commands.
Hand Measured (e.g., qnet)
double Tolerance() const
Return match algorithm tolerance.
Chip * PatternChip()
Return pointer to pattern chip.
void Write(const QString &filename)
Writes the contents of the Chip to a cube.
#define _FILEINFO_
Macro for the filename and line number.
void SetLogData(ControlMeasureLogData)
This adds or updates the log data information associated with data's type.
A type of error that could only have occurred due to a mistake on the user's part (e...
double UniversalLatitude() const
Returns the universal latitude of the camera model or projection.
double CubeLine() const
Return the search chip cube line that best matched.
double PatternValidPercent() const
Return pattern chip valid percent. The default value is.
QString expanded() const
Returns a QString of the full file name including the file path, excluding the attributes.
void geomChip(Chip *matchChip, Cube *matchChipCube)
Slot to geom chip (apply geometry transformation)
double zoomFactor()
Return the zoom factor.
bool Success() const
Return whether the match algorithm succeeded or not.
Fit chip did not have any valid data.
Container for cube-like labels.
void Load(Cube &cube, const double rotation=0.0, const double scale=1.0, const int band=1)
Load cube data into the Chip.
bool SetImage(double sample, double line)
Returns whether the sample/line postion was set successfully in the camera model or projection...
static AutoReg * Create(Pvl &pvl)
Create an AutoReg object using a PVL specification.
GoodnessOfFit is pointreg information for reference measures.
Goodness of fit tolerance not satisfied.
QString toString() const
Returns a string representation of this exception.
RegisterStatus
Enumeration of the Register() method's return status.
void Distance(double &sampDistance, double &lineDistance)
Return the distance point moved.
void setChip(Chip *chip, Cube *chipCube)
Set chip.
static QString UserName()
Returns the user name.
Status SetChooserName()
Set chooser name to a user who last changed the coordinate.
Namespace for ISIS/Bullet specific routines.
bool IsEditLocked() const
Return value for p_editLock or implicit lock on reference measure.
bool SetUniversalGround(double lat, double lon)
Returns whether the lat/lon position was set successfully in the camera model or projection.
Status SetCoordinate(double sample, double line)
Set the coordinate of the measurement.
Chip * FitChip()
Return pointer to fit chip.
void DeleteLogData(long dataType)
This deletes log data of the specified type.
Status SetDateTime()
Date Time - Creation Time.
Could not model surface for sub-pixel accuracy.
Pattern data max or min does not pass the z-score test.
double Sample() const
Returns the current line value of the camera model or projection.
void setCircle(bool checked)
Slot to change state of circle.
const int VIEWSIZE
Constant representing the length and width of the chip viewports.
Serial Number list generator.
double UniversalLongitude() const
Returns the universal longitude of the camera model or projection.
void loadView(ChipViewport &newView)
Load with another ChipViewport, used for blinking.
void nogeomChip()
Slot to un-geom chip (revert geometry transformation)
QString GetCubeSerialNumber() const
Return the serial number of the cube containing the coordinate.
IO Handler for Isis Cubes.