Satellite.hpp   Satellite.hpp 
skipping to change at line 98 skipping to change at line 98
//! with Satellite or SatelliteP objects can be sorted by satellite name/ID . //! with Satellite or SatelliteP objects can be sorted by satellite name/ID .
//! @ingroup satellites //! @ingroup satellites
class Satellite : public StelObject class Satellite : public StelObject
{ {
friend class Satellites; friend class Satellites;
friend class SatellitesDialog; friend class SatellitesDialog;
friend class SatellitesListModel; friend class SatellitesListModel;
Q_ENUMS(OptStatus) Q_ENUMS(OptStatus)
public: public:
static const QString SATELLITE_TYPE;
//! @enum OptStatus operational statuses //! @enum OptStatus operational statuses
enum OptStatus enum OptStatus
{ {
StatusOperational = 1, StatusOperational = 1,
StatusNonoperational = 2, StatusNonoperational = 2,
StatusPartiallyOperational = 3, StatusPartiallyOperational = 3,
StatusStandby = 4, StatusStandby = 4,
StatusSpare = 5, StatusSpare = 5,
StatusExtendedMission = 6, StatusExtendedMission = 6,
StatusDecayed = 7, StatusDecayed = 7,
skipping to change at line 123 skipping to change at line 125
//! (TLE set, description etc.) //! (TLE set, description etc.)
Satellite(const QString& identifier, const QVariantMap& data); Satellite(const QString& identifier, const QVariantMap& data);
~Satellite(); ~Satellite();
//! Get a QVariantMap which describes the satellite. Could be used to //! Get a QVariantMap which describes the satellite. Could be used to
//! create a duplicate. //! create a duplicate.
QVariantMap getMap(void); QVariantMap getMap(void);
virtual QString getType(void) const virtual QString getType(void) const
{ {
return "Satellite"; return SATELLITE_TYPE;
}
virtual QString getID(void) const
{
return id;
} }
virtual float getSelectPriority(const StelCore* core) const; virtual float getSelectPriority(const StelCore* core) const;
//! Get an HTML string to describe the object //! Get an HTML string to describe the object
//! @param core A pointer to the core //! @param core A pointer to the core
//! @param flags a set of flags with information types to include. //! @param flags a set of flags with information types to include.
//! Supported types for Satellite objects: //! Supported types for Satellite objects:
//! - Name: designation in large type with the description underneat h //! - Name: designation in large type with the description underneat h
//! - RaDecJ2000, RaDecOfDate, HourAngle, AltAzi //! - RaDecJ2000, RaDecOfDate, HourAngle, AltAzi
//! - Extra: range, range rate and altitude of satellite above the E arth, comms frequencies, modulation types and so on. //! - Extra: range, range rate and altitude of satellite above the E arth, comms frequencies, modulation types and so on.
virtual QString getInfoString(const StelCore *core, const InfoString Group& flags) const; virtual QString getInfoString(const StelCore *core, const InfoString Group& flags) const;
skipping to change at line 176 skipping to change at line 184
QString getCatalogNumberString() const {return id;} QString getCatalogNumberString() const {return id;}
//! Set new tleElements. This assumes the designation is already se t, populates //! Set new tleElements. This assumes the designation is already se t, populates
//! the tleElements values and configures internal orbit parameters. //! the tleElements values and configures internal orbit parameters.
void setNewTleElements(const QString& tle1, const QString& tle2); void setNewTleElements(const QString& tle1, const QString& tle2);
// calculate faders, new position // calculate faders, new position
void update(double deltaTime); void update(double deltaTime);
double getDoppler(double freq) const; double getDoppler(double freq) const;
static float showLabels; static bool showLabels;
static double roundToDp(float n, int dp); static double roundToDp(float n, int dp);
// when the observer location changes we need to // when the observer location changes we need to
void recalculateOrbitLines(void); void recalculateOrbitLines(void);
void setNew() {newlyAdded = true;} void setNew() {newlyAdded = true;}
bool isNew() const {return newlyAdded;} bool isNew() const {return newlyAdded;}
//! Get internal flags as a single value. //! Get internal flags as a single value.
SatFlags getFlags(); SatFlags getFlags() const;
//! Sets the internal flags in one operation (only display flags)! //! Sets the internal flags in one operation (only display flags)!
void setFlags(const SatFlags& flags); void setFlags(const SatFlags& flags);
//! Parse TLE line to extract International Designator and launch ye ar. //! Parse TLE line to extract International Designator and launch ye ar.
//! Sets #internationalDesignator and #jdLaunchYearJan1. //! Sets #internationalDesignator and #jdLaunchYearJan1.
void parseInternationalDesignator(const QString& tle1); void parseInternationalDesignator(const QString& tle1);
//! Needed for sorting lists (if this ever happens...). //! Needed for sorting lists (if this ever happens...).
//! Compares #name fields. If equal, #id fields, which can't be. //! Compares #name fields. If equal, #id fields, which can't be.
bool operator<(const Satellite& another) const; bool operator<(const Satellite& another) const;
//! Calculation of illuminated fraction of the satellite. //! Calculation of illuminated fraction of the satellite.
float calculateIlluminatedFraction() const; float calculateIlluminatedFraction() const;
//! Get operational status of satellite //! Get operational status of satellite
QString getOperationalStatus() const; QString getOperationalStatus() const;
private: private:
//draw orbits methods //draw orbits methods
void computeOrbitPoints(); void computeOrbitPoints();
void drawOrbit(StelPainter& painter); void drawOrbit(StelCore* core, StelPainter& painter);
//! returns 0 - 1.0 for the DRAWORBIT_FADE_NUMBER segments at //! returns 0 - 1.0 for the DRAWORBIT_FADE_NUMBER segments at
//! each end of an orbit, with 1 in the middle. //! each end of an orbit, with 1 in the middle.
float calculateOrbitSegmentIntensity(int segNum); float calculateOrbitSegmentIntensity(int segNum);
private: private:
bool initialized; bool initialized;
//! Flag indicating whether the satellite should be displayed. //! Flag indicating whether the satellite should be displayed.
//! Should not be confused with the pedicted visibility of the //! Should not be confused with the pedicted visibility of the
//! actual satellite to the observer. //! actual satellite to the observer.
bool displayed; bool displayed;
skipping to change at line 272 skipping to change at line 280
static float hintScale; static float hintScale;
static int orbitLineSegments; static int orbitLineSegments;
static int orbitLineFadeSegments; static int orbitLineFadeSegments;
static int orbitLineSegmentDuration; //measured in seconds static int orbitLineSegmentDuration; //measured in seconds
static bool orbitLinesFlag; static bool orbitLinesFlag;
static bool realisticModeFlag; static bool realisticModeFlag;
//! Mask controlling which info display flags should be honored. //! Mask controlling which info display flags should be honored.
static StelObject::InfoStringGroupFlags flagsMask; static StelObject::InfoStringGroupFlags flagsMask;
static Vec3f invisibleSatelliteColor; static Vec3f invisibleSatelliteColor;
void draw(StelCore *core, StelPainter& painter, float maxMagHints); static double timeRateLimit;
void draw(StelCore *core, StelPainter& painter);
//Satellite Orbit Position calculation //Satellite Orbit Position calculation
gSatWrapper *pSatWrapper; gSatWrapper *pSatWrapper;
Vec3d position; Vec3d position;
Vec3d velocity; Vec3d velocity;
Vec3d latLongSubPointPosition; Vec3d latLongSubPointPosition;
Vec3d elAzPosition; Vec3d elAzPosition;
#ifdef IRIDIUM_SAT_TEXT_DEBUG #ifdef IRIDIUM_SAT_TEXT_DEBUG
static QString myText; static QString myText;
#endif #endif
int visibility; gSatWrapper::Visibility visibility;
double phaseAngle; // phase angle for the satellite double phaseAngle; // phase angle for the satellite
static double sunReflAngle; // for Iridium satellites static double sunReflAngle; // for Iridium satellites
static double timeShift; // for Iridium satellites //static double timeShift; // for Iridium satellites UNUSED
//Satellite Orbit Draw //Satellite Orbit Draw
QFont font; QFont font;
Vec3f orbitColor; Vec3f orbitColor;
double lastEpochCompForOrbit; //measured in Julian Days double lastEpochCompForOrbit; //measured in Julian Days
double epochTime; //measured in Julian Days double epochTime; //measured in Julian Days
QList<Vec3d> orbitPoints; //orbit points represented by ElAzPos vect ors QList<Vec3d> orbitPoints; //orbit points represented by ElAzPos vect ors
QList<int> visibilityPoints; //orbit visibility points QList<gSatWrapper::Visibility> visibilityPoints; //orbit visibility points
}; };
typedef QSharedPointer<Satellite> SatelliteP; typedef QSharedPointer<Satellite> SatelliteP;
bool operator<(const SatelliteP& left, const SatelliteP& right); bool operator<(const SatelliteP& left, const SatelliteP& right);
#endif // _SATELLITE_HPP_ #endif // _SATELLITE_HPP_
 End of changes. 10 change blocks. 
8 lines changed or deleted 18 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/