Loading isis/src/control/objs/LidarControlPoint/LidarControlPoint.cpp 0 → 100644 +121 −0 Original line number Diff line number Diff line #include "LidarControlPoint.h" #include "ControlMeasure.h" #include "ControlPoint.h" #include "Cube.h" using namespace std; namespace Isis { /** * Empty LidarControlPoint constructor */ LidarControlPoint::LidarControlPoint() { m_time = -1; m_range = -1; m_sigmaRange = -1; } /** * Constructs a LidarControlPoint with the given time, range, and sigma range. * * @param time The time ths point was taken. * @param range The range of the point. * @param sigmaRange The sigmas od the range. */ LidarControlPoint::LidarControlPoint(double time, double range, double sigmaRange) { m_time = time; m_range = range; m_sigmaRange = sigmaRange; } /** * Copy the given LidarControlPoint * * @param other The LidarControlPoint to copy */ LidarControlPoint::LidarControlPoint(const LidarControlPoint &other) { m_time = other.time(); m_range = other.range(); m_sigmaRange = other.sigmaRange(); } /** * Destructor */ LidarControlPoint::~LidarControlPoint() { } /** * Set the time of the LidarControlPoint * * @param time The time to set */ void LidarControlPoint::setTime(double time) { if (time < 0.0) { QString msg = "The time must be greater then 0."; throw IException(IException::Unknown, msg, _FILEINFO_); return; } m_time = time; } /** * Set the range of the LidarControlPoint * * @param range The range to set */ void LidarControlPoint::setRange(double range) { if (range < 0.0) { QString msg = "The range must be greater then 0."; throw IException(IException::Unknown, msg, _FILEINFO_); return; } m_range = range; } /** * Sets the sigma range * * @param sigmaRange The sigma range to set */ void LidarControlPoint::setSigmaRange(double sigmaRange) { m_sigmaRange = sigmaRange; } /** * Returns the range of the point * * @return double The range */ double LidarControlPoint::range() { return m_range; } /** * Returns the time of the point * * @return double The time */ double LidarControlPoint::time() { return m_time; } /** * Returns the sigma range of the point * * @return double The sigma range double LidarControlPoint::sigmaRange() { return m_sigmaRange; } } isis/src/control/objs/LidarControlPoint/LidarControlPoint.h 0 → 100644 +66 −0 Original line number Diff line number Diff line #ifndef LidarControlPoint_h #define LidarControlPoint_h /** * @file * $Revision: 1.14 $ * $Date: 2009/09/08 17:38:17 $ * * Unless noted otherwise, the portions of Isis written by the USGS are * public domain. See individual third-party library and package descriptions * for intellectual property information, user agreements, and related * information. * * Although Isis has been used by the USGS, no warranty, expressed or * implied, is made by the USGS as to the accuracy and functioning of such * software and related material nor shall the fact of distribution * constitute any such warranty, and no responsibility is assumed by the * USGS in connection therewith. * * For additional information, launch * $ISISROOT/doc//documents/Disclaimers/Disclaimers.html * in a browser or see the Privacy & Disclaimers page on the Isis website, * http://isis.astrogeology.usgs.gov, and the USGS privacy and disclaimers on * http://www.usgs.gov/privacy.html. */ #include "ControlMeasure.h" #include "ControlPoint.h" #include "Cube.h" namespace Isis { /** * @brief A lidar control ControlPoint * * A lidar control point that extends from ControlPoint. Currently only works for LOLA data * * @author 2018-01-29 Makayla Shepherd * * @see ControlPoint */ class LidarControlPoint : public ControlPoint { public: LidarControlPoint(); LidarControlPoint(double time, double range, double time); LidarControlPoint(const LidarControlPoint &); ~LidarControlPoint(); void setRange(double range); void setSigmaRange(double sigmaRange); void setTime(double time); double range(); double sigmaRange(); double time(); ControlMeasure backProject(Cube cube); private: double m_range; double m_sigmaRange; double m_time; Loading
isis/src/control/objs/LidarControlPoint/LidarControlPoint.cpp 0 → 100644 +121 −0 Original line number Diff line number Diff line #include "LidarControlPoint.h" #include "ControlMeasure.h" #include "ControlPoint.h" #include "Cube.h" using namespace std; namespace Isis { /** * Empty LidarControlPoint constructor */ LidarControlPoint::LidarControlPoint() { m_time = -1; m_range = -1; m_sigmaRange = -1; } /** * Constructs a LidarControlPoint with the given time, range, and sigma range. * * @param time The time ths point was taken. * @param range The range of the point. * @param sigmaRange The sigmas od the range. */ LidarControlPoint::LidarControlPoint(double time, double range, double sigmaRange) { m_time = time; m_range = range; m_sigmaRange = sigmaRange; } /** * Copy the given LidarControlPoint * * @param other The LidarControlPoint to copy */ LidarControlPoint::LidarControlPoint(const LidarControlPoint &other) { m_time = other.time(); m_range = other.range(); m_sigmaRange = other.sigmaRange(); } /** * Destructor */ LidarControlPoint::~LidarControlPoint() { } /** * Set the time of the LidarControlPoint * * @param time The time to set */ void LidarControlPoint::setTime(double time) { if (time < 0.0) { QString msg = "The time must be greater then 0."; throw IException(IException::Unknown, msg, _FILEINFO_); return; } m_time = time; } /** * Set the range of the LidarControlPoint * * @param range The range to set */ void LidarControlPoint::setRange(double range) { if (range < 0.0) { QString msg = "The range must be greater then 0."; throw IException(IException::Unknown, msg, _FILEINFO_); return; } m_range = range; } /** * Sets the sigma range * * @param sigmaRange The sigma range to set */ void LidarControlPoint::setSigmaRange(double sigmaRange) { m_sigmaRange = sigmaRange; } /** * Returns the range of the point * * @return double The range */ double LidarControlPoint::range() { return m_range; } /** * Returns the time of the point * * @return double The time */ double LidarControlPoint::time() { return m_time; } /** * Returns the sigma range of the point * * @return double The sigma range double LidarControlPoint::sigmaRange() { return m_sigmaRange; } }
isis/src/control/objs/LidarControlPoint/LidarControlPoint.h 0 → 100644 +66 −0 Original line number Diff line number Diff line #ifndef LidarControlPoint_h #define LidarControlPoint_h /** * @file * $Revision: 1.14 $ * $Date: 2009/09/08 17:38:17 $ * * Unless noted otherwise, the portions of Isis written by the USGS are * public domain. See individual third-party library and package descriptions * for intellectual property information, user agreements, and related * information. * * Although Isis has been used by the USGS, no warranty, expressed or * implied, is made by the USGS as to the accuracy and functioning of such * software and related material nor shall the fact of distribution * constitute any such warranty, and no responsibility is assumed by the * USGS in connection therewith. * * For additional information, launch * $ISISROOT/doc//documents/Disclaimers/Disclaimers.html * in a browser or see the Privacy & Disclaimers page on the Isis website, * http://isis.astrogeology.usgs.gov, and the USGS privacy and disclaimers on * http://www.usgs.gov/privacy.html. */ #include "ControlMeasure.h" #include "ControlPoint.h" #include "Cube.h" namespace Isis { /** * @brief A lidar control ControlPoint * * A lidar control point that extends from ControlPoint. Currently only works for LOLA data * * @author 2018-01-29 Makayla Shepherd * * @see ControlPoint */ class LidarControlPoint : public ControlPoint { public: LidarControlPoint(); LidarControlPoint(double time, double range, double time); LidarControlPoint(const LidarControlPoint &); ~LidarControlPoint(); void setRange(double range); void setSigmaRange(double sigmaRange); void setTime(double time); double range(); double sigmaRange(); double time(); ControlMeasure backProject(Cube cube); private: double m_range; double m_sigmaRange; double m_time;