1 #include "QnetPointRangeFilter.h" 37 m_minlat =
new QLineEdit;
38 m_maxlat =
new QLineEdit;
39 m_minlon =
new QLineEdit;
40 m_maxlon =
new QLineEdit;
49 QLabel *minlatLabel =
new QLabel(
"Minimum Latitude");
50 QLabel *maxlatLabel =
new QLabel(
"Maximum Latitude");
51 QLabel *minlonLabel =
new QLabel(
"Minimum Longitude");
52 QLabel *maxlonLabel =
new QLabel(
"Maximum Longitude");
53 QLabel *pad =
new QLabel();
56 QGridLayout *gridLayout =
new QGridLayout();
57 gridLayout->addWidget(minlatLabel, 0, 0, 1, 1);
58 gridLayout->addWidget(m_minlat, 0, 1, 1, 1);
59 gridLayout->addWidget(maxlatLabel, 1, 0, 1, 1);
60 gridLayout->addWidget(m_maxlat, 1, 1, 1, 1);
61 gridLayout->addWidget(minlonLabel, 2, 0, 1, 1);
62 gridLayout->addWidget(m_minlon, 2, 1, 1, 1);
63 gridLayout->addWidget(maxlonLabel, 3, 0, 1, 1);
64 gridLayout->addWidget(m_maxlon, 3, 1, 1, 1);
65 gridLayout->addWidget(pad, 4, 0);
66 gridLayout->setRowStretch(4, 50);
67 this->setLayout(gridLayout);
86 if (controlNet() == NULL) {
87 QMessageBox::information((
QWidget *)parent(),
88 "Error",
"No points to filter");
93 if ((m_minlat->text() ==
"") || (m_maxlat->text() ==
"") ||
94 (m_minlon->text() ==
"") || (m_maxlon->text() ==
"")) {
95 QMessageBox::information((
QWidget *)parent(),
96 "Error",
"All lat/lon range values must be entered");
101 double minlat = m_minlat->text().toDouble();
102 double maxlat = m_maxlat->text().toDouble();
103 double minlon = m_minlon->text().toDouble();
104 double maxlon = m_maxlon->text().toDouble();
107 if (minlat > maxlat) {
108 QString msg =
"The minimum latitude value must be less than the maximum latitude value";
109 QMessageBox::information((
QWidget *)parent(),
"Error", msg);
113 else if (minlon > maxlon) {
114 QString msg =
"The minimum longitude value must be less than the maximum longitude value";
115 QMessageBox::information((
QWidget *)parent(),
"Error", msg);
122 for (
int i = filteredPoints().size() - 1; i >= 0; i--) {
124 ControlPoint &cp = *(*controlNet())[filteredPoints()[i]];
133 filteredPoints().removeAt(i);
140 emit filteredListModified();
Namespace for the standard library.
This class is designed to encapsulate the concept of a Latitude.
SurfacePoint GetBestSurfacePoint() const
Returns the adjusted surface point if it exists, otherwise returns the a priori surface point...
Latitude GetLatitude() const
Return the body-fixed latitude for the surface point.
This class is designed to encapsulate the concept of a Longitude.
bool inRange(Latitude min, Latitude max) const
Checks if this latitude value is within the given range.
Degrees are generally considered more human readable, 0-360 is one circle, however most math does not...
Unless noted otherwise, the portions of Isis written by the USGS are public domain.
Longitude GetLongitude() const
Return the body-fixed longitude for the surface point.
virtual void filter()
Filters a list of points for points that are of the selected Range or in the given range...
Namespace for ISIS/Bullet specific routines.
bool inRange(Longitude min, Longitude max) const
Checks if this longitude value is within the given range.
Unless noted otherwise, the portions of Isis written by the USGS are public domain.