Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
GeospatialOperations.hpp
Go to the documentation of this file.
1
12#ifndef GEOSPATIAL_OPERATIONS_HPP
13#define GEOSPATIAL_OPERATIONS_HPP
14
15#include "../AutonomyLogging.h"
16
18#include <GeographicLib/Geodesic.hpp>
19#include <GeographicLib/UTMUPS.hpp>
20#include <chrono>
21
23
24
32namespace geoops
33{
35 // Declare public enums.
37
38 // This enum is used to store values for the waypoint type.
39 enum class WaypointType
40 {
41 eNavigationWaypoint,
42 eTagWaypoint,
43 eMalletWaypoint,
44 eWaterBottleWaypoint,
45 eRockPickWaypoint,
46 eObjectWaypoint, // Used to represent either Mallet, WaterBottle, or RockPick waypoint.
47 eObstacleWaypoint,
48 eUNKNOWN
49 };
50
51 // This enum is used to store the location fix type for a UTM or GPS points, the enum indexes follow the UBLOX-F9P docs.
52 enum class PositionFixType
53 {
54 eNoFix,
55 eDeadReckoning,
56 eFix2D,
57 eFix3D,
58 eGNSSDeadReckoningCombined,
59 eTimeOnly,
60 eUNKNOWN
61 };
62
64 // Declare public variables.
66
68 // Declare public structs that are specific to and used within this class.
70
71
83 {
84 public:
85 // Define public struct attributes.
86 double dDistanceMeters; // The great circle distance between the two points.
87 double dArcLengthDegrees; // The degree measurement difference between the two points from the center of the sphere. (0, 180)
88 double dStartRelativeBearing; // The relative bearing in degrees from the first point to the second point for the shortest great circle path. (0, 360)
89 double dEndRelativeBearing; // The relative bearing in degrees from the second point to the first point for the shortest great circle path. (0, 360)
90 };
91
92
100 {
101 public:
102 // Declare struct public attributes
103 double dLatitude; // The geographic latitude in degrees, typically within the range [-90, 90].
104 double dLongitude; // The geographic longitude in degrees, typically within the range [-180, 180].
105 double dAltitude; // The elevation above sea level in meters.
106 double d2DAccuracy; // The horizontal accuracy of the GPS coordinates in meters.
107 double d3DAccuracy; // The three-dimensional accuracy, including altitude, in meters.
108 double dMeridianConvergence; // The angle between true north and grid north at the given location in degrees. Positive in eastern direction.
109 double dScale; // The scale factor applied to the UTM coordinates for map projection.
110 PositionFixType eCoordinateAccuracyFixType; // The type of satellite location lock the coordinate was taken under.
111 bool bIsDifferential; // Whether of not the coordinate was taken under a differential GPS lock.
112 std::chrono::system_clock::time_point tmTimestamp; // The chrono time point when the GPS coordinate was created/received.
113
115 // Declare public methods.
117
133 GPSCoordinate(double dLatitude = 0.0,
134 double dLongitude = 0.0,
135 double dAltitude = 0.0,
136 double d2DAccuracy = -1.0,
137 double d3DAccuracy = -1.0,
138 double dMeridianConvergence = -1.0,
139 double dScale = 0.0,
140 PositionFixType eCoordinateAccuracyFixType = PositionFixType::eUNKNOWN,
141 bool bIsDifferential = false,
142 std::chrono::system_clock::time_point tmTimestamp = std::chrono::system_clock::time_point().min())
143 {
144 // Initialize member variables with given values.
145 this->dLatitude = dLatitude;
146 this->dLongitude = dLongitude;
147 this->dAltitude = dAltitude;
148 this->d2DAccuracy = d2DAccuracy;
149 this->d3DAccuracy = d3DAccuracy;
150 this->dMeridianConvergence = dMeridianConvergence;
151 this->dScale = dScale;
152 this->eCoordinateAccuracyFixType = eCoordinateAccuracyFixType;
153 this->bIsDifferential = bIsDifferential;
154 this->tmTimestamp = tmTimestamp;
155 }
156
157
167 bool operator==(const GPSCoordinate& stOtherCoordinate) const
168 {
169 // Check if location, altitude, and accuracy are the same. Not going to worry about other values for now.
170 return (dLatitude == stOtherCoordinate.dLatitude && dLongitude == stOtherCoordinate.dLongitude && dAltitude == stOtherCoordinate.dAltitude &&
171 d2DAccuracy == stOtherCoordinate.d2DAccuracy && d3DAccuracy == stOtherCoordinate.d3DAccuracy &&
172 eCoordinateAccuracyFixType == stOtherCoordinate.eCoordinateAccuracyFixType && bIsDifferential == stOtherCoordinate.bIsDifferential);
173 }
174
175
185 bool operator!=(const GPSCoordinate& stOtherCoordinate) const { return !this->operator==(stOtherCoordinate); }
186
187
195 std::string ToString() const
196 {
197 std::ostringstream oss;
198 oss << "Latitude: " << dLatitude << ", Longitude: " << dLongitude << ", Altitude: " << dAltitude;
199 return oss.str();
200 }
201 };
202
203
211 {
212 public:
213 // Declare struct public attributes.
214 double dEasting; // The eastward displacement from the UTM zone's central meridian in meters.
215 double dNorthing; // The northward displacement from the equator in meters.
216 int nZone; // The UTM zone number identifying the region on the Earth's surface.
217 bool bWithinNorthernHemisphere; // Indicates whether the coordinate is located in the northern hemisphere.
218 double dAltitude; // The elevation above sea level in meters.
219 double d2DAccuracy; // The horizontal accuracy of the UTM coordinates in meters.
220 double d3DAccuracy; // The three-dimensional accuracy, including altitude, in meters.
221 double dMeridianConvergence; // The angle between true north and grid north at the given location in degrees. Positive in eastern direction.
222 double dScale; // The scale factor applied to the UTM coordinates for map projection.
223 PositionFixType eCoordinateAccuracyFixType; // The type of satellite location lock the coordinate was taken under.
224 bool bIsDifferential; // Whether of not the coordinate was taken under a differential GPS lock.
225 std::chrono::system_clock::time_point tmTimestamp; // The chrono time point when the GPS coordinate was created/received.
226
228 // Declare public methods.
230
231
249 UTMCoordinate(double dEasting = 0.0,
250 double dNorthing = 0.0,
251 int nZone = 0,
252 bool bWithinNorthernHemisphere = true,
253 double dAltitude = 0.0,
254 double d2DAccuracy = -1.0,
255 double d3DAccuracy = -1.0,
256 double dMeridianConvergence = -1.0,
257 double dScale = 0.0,
258 PositionFixType eCoordinateAccuracyFixType = PositionFixType::eUNKNOWN,
259 bool bIsDifferential = false,
260 std::chrono::system_clock::time_point tmTimestamp = std::chrono::system_clock::time_point().min())
261 {
262 // Initialize member variables with given values.
263 this->dEasting = dEasting;
264 this->dNorthing = dNorthing;
265 this->nZone = nZone;
266 this->bWithinNorthernHemisphere = bWithinNorthernHemisphere;
267 this->dAltitude = dAltitude;
268 this->d2DAccuracy = d2DAccuracy;
269 this->d3DAccuracy = d3DAccuracy;
270 this->dMeridianConvergence = dMeridianConvergence;
271 this->dScale = dScale;
272 this->eCoordinateAccuracyFixType = eCoordinateAccuracyFixType;
273 this->bIsDifferential = bIsDifferential;
274 this->tmTimestamp = tmTimestamp;
275 }
276
277
287 bool operator==(const UTMCoordinate& stOtherCoordinate) const
288 {
289 // Check if location, altitude, and accuracy are the same. Not going to worry about other values for now.
290 return (dEasting == stOtherCoordinate.dEasting && dNorthing == stOtherCoordinate.dNorthing && nZone == stOtherCoordinate.nZone &&
291 bWithinNorthernHemisphere == stOtherCoordinate.bWithinNorthernHemisphere && dAltitude == stOtherCoordinate.dAltitude &&
292 d2DAccuracy == stOtherCoordinate.d2DAccuracy && d3DAccuracy == stOtherCoordinate.d3DAccuracy &&
293 eCoordinateAccuracyFixType == stOtherCoordinate.eCoordinateAccuracyFixType && bIsDifferential == stOtherCoordinate.bIsDifferential);
294 }
295
296
306 bool operator!=(const UTMCoordinate& stOtherCoordinate) const { return !this->operator==(stOtherCoordinate); }
307
308
316 std::string ToString() const
317 {
318 std::ostringstream oss;
319 oss << "Easting: " << dEasting << ", Northing: " << dNorthing << ", Altitude: " << dAltitude;
320 return oss.str();
321 }
322 };
323
324
334 {
335 // Create instance variables.
336 UTMCoordinate stConvertCoord;
337
338 // Get data out of the GPS coord and repackage it into the UTM struct.
339 stConvertCoord.d2DAccuracy = stGPSCoord.d2DAccuracy;
340 stConvertCoord.d3DAccuracy = stGPSCoord.d3DAccuracy;
341 stConvertCoord.dAltitude = stGPSCoord.dAltitude;
342 stConvertCoord.eCoordinateAccuracyFixType = stGPSCoord.eCoordinateAccuracyFixType;
343 stConvertCoord.bIsDifferential = stGPSCoord.bIsDifferential;
344 stConvertCoord.tmTimestamp = stGPSCoord.tmTimestamp;
345
346 // Catch errors from GeographicLib.
347 try
348 {
349 // Forward solve for the UTM coord.
350 GeographicLib::UTMUPS::Forward(stGPSCoord.dLatitude,
351 stGPSCoord.dLongitude,
352 stConvertCoord.nZone,
353 stConvertCoord.bWithinNorthernHemisphere,
354 stConvertCoord.dEasting,
355 stConvertCoord.dNorthing,
356 stConvertCoord.dMeridianConvergence,
357 stConvertCoord.dScale);
358 }
359 catch (const GeographicLib::GeographicErr::exception& geError)
360 {
361 // Submit logger message.
362 LOG_ERROR(logging::g_qSharedLogger, "Unable to forward solve a GPSCoordinate to UTMCoordinate. GeographicLib error is: {}", geError.what());
363 }
364
365 // Return the converted UTM coordinate.
366 return stConvertCoord;
367 }
368
369
379 {
380 // Create instance variables.
381 GPSCoordinate stConvertCoord;
382
383 // Get data out of the UTM coord and repackage it into the GPS struct.
384 stConvertCoord.d2DAccuracy = stUTMCoord.d2DAccuracy;
385 stConvertCoord.d3DAccuracy = stUTMCoord.d3DAccuracy;
386 stConvertCoord.dAltitude = stUTMCoord.dAltitude;
387 stConvertCoord.eCoordinateAccuracyFixType = stUTMCoord.eCoordinateAccuracyFixType;
388 stConvertCoord.bIsDifferential = stUTMCoord.bIsDifferential;
389 stConvertCoord.tmTimestamp = stUTMCoord.tmTimestamp;
390
391 // Catch errors from GeographicLib.
392 try
393 {
394 // Reverse solve for the UTM coord.
395 GeographicLib::UTMUPS::Reverse(stUTMCoord.nZone,
396 stUTMCoord.bWithinNorthernHemisphere,
397 std::fabs(stUTMCoord.dEasting),
398 stUTMCoord.dNorthing,
399 stConvertCoord.dLatitude,
400 stConvertCoord.dLongitude,
401 stConvertCoord.dMeridianConvergence,
402 stConvertCoord.dScale);
403 }
404 catch (const GeographicLib::GeographicErr::exception& geError)
405 {
406 // Submit logger message.
407 LOG_ERROR(logging::g_qSharedLogger, "Unable to reverse solve a UTMCoordinate to GPSCoordinate. GeographicLib error is: {}", geError.what());
408 }
409
410 // Return the converted UTM coordinate.
411 return stConvertCoord;
412 }
413
414
422 struct Waypoint
423 {
424 private:
425 // Declare struct private member variables.
426 geoops::GPSCoordinate stGPSLocation; // This is not meant to be changed once this waypoint is created.
427 geoops::UTMCoordinate stUTMLocation; // This is not meant to be changed once this waypoint is created.
428
429 public:
430 // Declare struct public member variables.
431 WaypointType eType;
432 double dRadius;
433 int nID;
434
435
451 const WaypointType& eType = WaypointType::eUNKNOWN,
452 const double dRadius = 0.0,
453 const int nID = -1)
454 {
455 // Initialize member variables.
456 this->stGPSLocation = stGPSLocation;
457 this->stUTMLocation = geoops::ConvertGPSToUTM(stGPSLocation);
458 this->eType = eType;
459 this->dRadius = dRadius;
460 this->nID = nID;
461 }
462
463
478 Waypoint(const geoops::UTMCoordinate& stUTMLocation, const WaypointType& eType = WaypointType::eUNKNOWN, const double dRadius = 0.0, const int nID = -1)
479 {
480 // Initialize member variables.
481 this->stUTMLocation = stUTMLocation;
482 this->stGPSLocation = geoops::ConvertUTMToGPS(stUTMLocation);
483 this->eType = eType;
484 this->dRadius = dRadius;
485 this->nID = nID;
486 }
487
488
497 const geoops::GPSCoordinate& GetGPSCoordinate() const { return stGPSLocation; }
498
499
508 const geoops::UTMCoordinate& GetUTMCoordinate() const { return stUTMLocation; }
509
510
520 bool operator==(const Waypoint& stOtherWaypoint) const
521 {
522 // Check if location, altitude, and accuracy are the same. Not going to worry about other values for now.
523 return (stGPSLocation == stOtherWaypoint.stGPSLocation && stUTMLocation == stOtherWaypoint.stUTMLocation && eType == stOtherWaypoint.eType &&
524 dRadius == stOtherWaypoint.dRadius && nID == stOtherWaypoint.nID);
525 }
526
527
537 bool operator!=(const Waypoint& stOtherWaypoint) const { return !this->operator==(stOtherWaypoint); }
538 };
539
540
553 inline GeoMeasurement CalculateGeoMeasurement(const GPSCoordinate& stCoord1, const GPSCoordinate& stCoord2)
554 {
555 // Create instance variables.
556 GeoMeasurement stMeasurements;
557
558 // Construct a geodesic with earth characteristics. (Radius and flattening)
559 // The WGS84 standard is widely used and aligns with Google Maps.
560 GeographicLib::Geodesic geGeodesic = GeographicLib::Geodesic::WGS84();
561
562 // Solve the inverse geodesic for distance and arc length degrees at the center of the globe, and relative bearings.
563 stMeasurements.dArcLengthDegrees = geGeodesic.Inverse(stCoord1.dLatitude,
564 stCoord1.dLongitude,
565 stCoord2.dLatitude,
566 stCoord2.dLongitude,
567 stMeasurements.dDistanceMeters,
568 stMeasurements.dStartRelativeBearing,
569 stMeasurements.dEndRelativeBearing);
570
571 // NOTE: Regarding azi1 vs azi2, azi1 is the direction measured at point 1 (your navigation aid) to point 2. azi2 is the direction measured at point 2 (your
572 // location) away from point 1. (If you want the direction to point 1, add ±180° to azi2.)
573 // Map the -180, 180 range of the azimuths to 0, 360, with both points zeroed at North.
574 stMeasurements.dStartRelativeBearing = std::fmod((stMeasurements.dStartRelativeBearing + 360), 360);
575 stMeasurements.dEndRelativeBearing = std::fmod((stMeasurements.dEndRelativeBearing + 180), 360);
576 // Ensure the result angle is positive.
577 if (stMeasurements.dStartRelativeBearing < 0)
578 {
579 // Add 360 degrees.
580 stMeasurements.dStartRelativeBearing += 360;
581 }
582 // Ensure the result angle is positive.
583 if (stMeasurements.dEndRelativeBearing < 0)
584 {
585 // Add 360 degrees.
586 stMeasurements.dEndRelativeBearing += 360;
587 }
588
589 // Return result distance.
590 return stMeasurements;
591 }
592
593
606 inline GeoMeasurement CalculateGeoMeasurement(const UTMCoordinate& stCoord1, const UTMCoordinate& stCoord2)
607 {
608 // Create instance variables.
609 GeoMeasurement stMeasurements;
610
611 // Construct a geodesic with earth characteristics. (Radius and flattening)
612 // The WGS84 standard is widely used and aligns with Google Maps.
613 GeographicLib::Geodesic geGeodesic = GeographicLib::Geodesic::WGS84();
614
615 // Convert the given UTM coords into GPS coords for temporary use.
616 GPSCoordinate stGPSCoord1 = ConvertUTMToGPS(stCoord1);
617 GPSCoordinate stGPSCoord2 = ConvertUTMToGPS(stCoord2);
618
619 // Solve the inverse geodesic.
620 stMeasurements.dArcLengthDegrees = geGeodesic.Inverse(stGPSCoord1.dLatitude,
621 stGPSCoord1.dLongitude,
622 stGPSCoord2.dLatitude,
623 stGPSCoord2.dLongitude,
624 stMeasurements.dDistanceMeters,
625 stMeasurements.dStartRelativeBearing,
626 stMeasurements.dEndRelativeBearing);
627
628 // NOTE: Regarding azi1 vs azi2, azi1 is the direction measured at point 1 (your navigation aid) to point 2. azi2 is the direction measured at point 2 (your
629 // location) away from point 1. (If you want the direction to point 1, add ±180° to azi2.)
630 // Map the -180, 180 range of the azimuths to 0, 360, with both points zeroed at North.
631 stMeasurements.dStartRelativeBearing = std::fmod((stMeasurements.dStartRelativeBearing + 360), 360);
632 stMeasurements.dEndRelativeBearing = std::fmod((stMeasurements.dEndRelativeBearing + 180), 360);
633 // Ensure the result angle is positive.
634 if (stMeasurements.dStartRelativeBearing < 0)
635 {
636 // Add 360 degrees.
637 stMeasurements.dStartRelativeBearing += 360;
638 }
639 // Ensure the result angle is positive.
640 if (stMeasurements.dEndRelativeBearing < 0)
641 {
642 // Add 360 degrees.
643 stMeasurements.dEndRelativeBearing += 360;
644 }
645
646 // Return result distance.
647 return stMeasurements;
648 }
649
650
660 inline GeoMeasurement CalculateGeoMeasurement(const geoops::Waypoint& stWaypoint1, const geoops::Waypoint& stWaypoint2)
661 {
662 // Create instance variables.
663 GeoMeasurement stMeasurements;
664
665 // Construct a geodesic with earth characteristics. (Radius and flattening)
666 // The WGS84 standard is widely used and aligns with Google Maps.
667 GeographicLib::Geodesic geGeodesic = GeographicLib::Geodesic::WGS84();
668
669 // Solve the inverse geodesic.
670 stMeasurements.dArcLengthDegrees = geGeodesic.Inverse(stWaypoint1.GetGPSCoordinate().dLatitude,
671 stWaypoint1.GetGPSCoordinate().dLongitude,
672 stWaypoint2.GetGPSCoordinate().dLatitude,
673 stWaypoint2.GetGPSCoordinate().dLongitude,
674 stMeasurements.dDistanceMeters,
675 stMeasurements.dStartRelativeBearing,
676 stMeasurements.dEndRelativeBearing);
677
678 // NOTE: Regarding azi1 vs azi2, azi1 is the direction measured at point 1 (your navigation aid) to point 2. azi2 is the direction measured at point 2 (your
679 // location) away from point 1. (If you want the direction to point 1, add ±180° to azi2.)
680 // Map the -180, 180 range of the azimuths to 0, 360, with both points zeroed at North.
681 stMeasurements.dStartRelativeBearing = std::fmod((stMeasurements.dStartRelativeBearing + 360), 360);
682 stMeasurements.dEndRelativeBearing = std::fmod((stMeasurements.dEndRelativeBearing + 180), 360);
683 // Ensure the result angle is positive.
684 if (stMeasurements.dStartRelativeBearing < 0)
685 {
686 // Add 360 degrees.
687 stMeasurements.dStartRelativeBearing += 360;
688 }
689 // Ensure the result angle is positive.
690 if (stMeasurements.dEndRelativeBearing < 0)
691 {
692 // Add 360 degrees.
693 stMeasurements.dEndRelativeBearing += 360;
694 }
695
696 // Return result distance.
697 return stMeasurements;
698 }
699
700
708 {
709 private:
710 // Declare struct private member variables.
711 Waypoint stRoverPosition; // Stores the rover's 3D location in UTM and GPS form.
712 double dRoverHeading; // Stores the rover's compass heading. North = 0, CW=pos
713
714 public:
715
724 RoverPose(const geoops::GPSCoordinate& stRoverPosition = geoops::GPSCoordinate(), const double dRoverHeading = 0.0)
725 {
726 // Update member variables.
727 this->stRoverPosition = Waypoint(stRoverPosition);
728 this->dRoverHeading = dRoverHeading;
729 }
730
731
740 RoverPose(const geoops::UTMCoordinate& stRoverPosition, const double dRoverHeading = 0.0)
741 {
742 // Update member variables.
743 this->stRoverPosition = Waypoint(stRoverPosition);
744 this->dRoverHeading = dRoverHeading;
745 }
746
747
756 const geoops::GPSCoordinate& GetGPSCoordinate() const { return stRoverPosition.GetGPSCoordinate(); }
757
758
767 const geoops::UTMCoordinate& GetUTMCoordinate() const { return stRoverPosition.GetUTMCoordinate(); }
768
769
777 const geoops::Waypoint& GetWaypoint() const { return stRoverPosition; }
778
779
787 double GetCompassHeading() const { return dRoverHeading; }
788
789
799 bool operator==(const RoverPose& stOtherRoverPose) const
800 {
801 // Check if location, altitude, and accuracy are the same. Not going to worry about other values for now.
802 return (stRoverPosition == stOtherRoverPose.GetGPSCoordinate() && stRoverPosition == stOtherRoverPose.GetUTMCoordinate() &&
803 dRoverHeading == stOtherRoverPose.dRoverHeading);
804 }
805
806
816 bool operator!=(const RoverPose& stOtherRoverPose) const { return !this->operator==(stOtherRoverPose); }
817 };
818} // namespace geoops
819#endif
static softfloat min()
Namespace containing functions related to operations on global position number systems and other data...
Definition GeospatialOperations.hpp:33
GPSCoordinate ConvertUTMToGPS(const UTMCoordinate &stUTMCoord)
Given a UTM coordinate, convert to GPS and create a new GPSCoordinate object.
Definition GeospatialOperations.hpp:378
UTMCoordinate ConvertGPSToUTM(const GPSCoordinate &stGPSCoord)
Given a GPS coordinate, convert to UTM and create a new UTMCoordinate object.
Definition GeospatialOperations.hpp:333
GeoMeasurement CalculateGeoMeasurement(const GPSCoordinate &stCoord1, const GPSCoordinate &stCoord2)
The shortest path between two points on an ellipsoid at (lat1, lon1) and (lat2, lon2) is called the g...
Definition GeospatialOperations.hpp:553
This struct stores/contains information about a GPS data.
Definition GeospatialOperations.hpp:100
GPSCoordinate(double dLatitude=0.0, double dLongitude=0.0, double dAltitude=0.0, double d2DAccuracy=-1.0, double d3DAccuracy=-1.0, double dMeridianConvergence=-1.0, double dScale=0.0, PositionFixType eCoordinateAccuracyFixType=PositionFixType::eUNKNOWN, bool bIsDifferential=false, std::chrono::system_clock::time_point tmTimestamp=std::chrono::system_clock::time_point().min())
Construct a new GPSCoordinate object.
Definition GeospatialOperations.hpp:133
bool operator!=(const GPSCoordinate &stOtherCoordinate) const
Overridden operator not equals for GPSCoordinate struct.
Definition GeospatialOperations.hpp:185
bool operator==(const GPSCoordinate &stOtherCoordinate) const
Overridden operator equals for GPSCoordinate struct.
Definition GeospatialOperations.hpp:167
std::string ToString() const
Converts the GPSCoordinate to a string representation.
Definition GeospatialOperations.hpp:195
This struct is used to store the distance, arc length, and relative bearing for a calculated geodesic...
Definition GeospatialOperations.hpp:83
This struct is used by the WaypointHandler to provide an easy way to store all pose data about the ro...
Definition GeospatialOperations.hpp:708
RoverPose(const geoops::GPSCoordinate &stRoverPosition=geoops::GPSCoordinate(), const double dRoverHeading=0.0)
Construct a new Rover Pose object.
Definition GeospatialOperations.hpp:724
bool operator==(const RoverPose &stOtherRoverPose) const
Overridden operator equals for RoverPose struct.
Definition GeospatialOperations.hpp:799
const geoops::GPSCoordinate & GetGPSCoordinate() const
Accessor for the geoops::GPSCoordinate member variable.
Definition GeospatialOperations.hpp:756
bool operator!=(const RoverPose &stOtherRoverPose) const
Overridden operator equals for RoverPose struct.
Definition GeospatialOperations.hpp:816
double GetCompassHeading() const
Accessor for the Compass Heading private member.
Definition GeospatialOperations.hpp:787
const geoops::UTMCoordinate & GetUTMCoordinate() const
Accessor for the geoops::UTMCoordinate member variable.
Definition GeospatialOperations.hpp:767
RoverPose(const geoops::UTMCoordinate &stRoverPosition, const double dRoverHeading=0.0)
Construct a new Rover Pose object.
Definition GeospatialOperations.hpp:740
const geoops::Waypoint & GetWaypoint() const
Accessor for the Waypoint private member.
Definition GeospatialOperations.hpp:777
This struct stores/contains information about a UTM coordinate.
Definition GeospatialOperations.hpp:211
UTMCoordinate(double dEasting=0.0, double dNorthing=0.0, int nZone=0, bool bWithinNorthernHemisphere=true, double dAltitude=0.0, double d2DAccuracy=-1.0, double d3DAccuracy=-1.0, double dMeridianConvergence=-1.0, double dScale=0.0, PositionFixType eCoordinateAccuracyFixType=PositionFixType::eUNKNOWN, bool bIsDifferential=false, std::chrono::system_clock::time_point tmTimestamp=std::chrono::system_clock::time_point().min())
Construct a new UTMCoordinate object.
Definition GeospatialOperations.hpp:249
bool operator==(const UTMCoordinate &stOtherCoordinate) const
Overridden operator equals for UTMCoordinate struct.
Definition GeospatialOperations.hpp:287
bool operator!=(const UTMCoordinate &stOtherCoordinate) const
Overridden operator not equals for UTMCoordinate struct.
Definition GeospatialOperations.hpp:306
std::string ToString() const
Converts the UTMCoordinate to a string representation.
Definition GeospatialOperations.hpp:316
This struct is used by the WaypointHandler class to store location, size, and type information about ...
Definition GeospatialOperations.hpp:423
const geoops::GPSCoordinate & GetGPSCoordinate() const
Accessor for the geoops::GPSCoordinate member variable.
Definition GeospatialOperations.hpp:497
bool operator==(const Waypoint &stOtherWaypoint) const
Overridden operator equals for Waypoint struct.
Definition GeospatialOperations.hpp:520
Waypoint(const geoops::GPSCoordinate &stGPSLocation=geoops::GPSCoordinate(), const WaypointType &eType=WaypointType::eUNKNOWN, const double dRadius=0.0, const int nID=-1)
Construct a new Waypoint object.
Definition GeospatialOperations.hpp:450
bool operator!=(const Waypoint &stOtherWaypoint) const
Overridden operator equals for Waypoint struct.
Definition GeospatialOperations.hpp:537
Waypoint(const geoops::UTMCoordinate &stUTMLocation, const WaypointType &eType=WaypointType::eUNKNOWN, const double dRadius=0.0, const int nID=-1)
Construct a new Waypoint object.
Definition GeospatialOperations.hpp:478
const geoops::UTMCoordinate & GetUTMCoordinate() const
Accessor for the geoops::UTMCoordinate member variable.
Definition GeospatialOperations.hpp:508