Planet.hpp   Planet.hpp 
skipping to change at line 78 skipping to change at line 78
const float radiusMax; const float radiusMax;
StelTextureSP tex; StelTextureSP tex;
}; };
class Planet : public StelObject class Planet : public StelObject
{ {
public: public:
friend class SolarSystem; friend class SolarSystem;
Q_ENUMS(PlanetType) Q_ENUMS(PlanetType)
Q_ENUMS(PlanetOrbitColorStyle)
Q_ENUMS(ApparentMagnitudeAlgorithm) Q_ENUMS(ApparentMagnitudeAlgorithm)
//! numeric typecodes for the type descriptions in ssystem.ini //! numeric typecodes for the type descriptions in ssystem.ini
// GZ: Until 0.13 QStrings were used for types. // GZ: Until 0.13 QStrings were used for types.
// GZ: Enums are slightly faster than string comparisons in time-cri tical comparisons. // GZ: Enums are slightly faster than string comparisons in time-cri tical comparisons.
// GZ: If other types are introduced, add here and the string in ini t(). // GZ: If other types are introduced, add here and the string in ini t().
enum PlanetType enum PlanetType
{ {
isStar, // ssystem.ini: type="star" isStar, // ssystem.ini: type="star"
isPlanet, // ssystem.ini: type="planet" isPlanet, // ssystem.ini: type="planet"
isMoon, // ssystem.ini: type="moon" isMoon, // ssystem.ini: type="moon"
isAsteroid, // ssystem.ini: type="asteroid" isAsteroid, // ssystem.ini: type="asteroid"
isPlutino, // ssystem.ini: type="plutino" isPlutino, // ssystem.ini: type="plutino"
isComet, // ssystem.ini: type="comet" isComet, // ssystem.ini: type="comet"
isDwarfPlanet, // ssystem.ini: type="dwarf planet isDwarfPlanet, // ssystem.ini: type="dwarf planet"
" isCubewano, // ssystem.ini: type="cubewano"
isCubewano, // ssystem.ini: type="cubewano" isSDO, // ssystem.ini: type="sdo"
isSDO, // ssystem.ini: type="sdo" isOCO, // ssystem.ini: type="oco"
isOCO, // ssystem.ini: type="oco" isUNDEFINED // ssystem.ini: type=<anything else>
isUNDEFINED // ssystem.ini: type=<anything els };
e>
enum PlanetOrbitColorStyle
{
ocsOneColor, // One color for all orbits
ocsGroups, // Separate colors for each group of
Solar system bodies
ocsMajorPlanets // Separate colors for each of major
planets of Solar system
}; };
enum ApparentMagnitudeAlgorithm enum ApparentMagnitudeAlgorithm
{ {
Planesas, // Algorithm provided by Pere Planesas (Obse Planesas, // Algorithm provided by Pere Planes
rvatorio Astronomico Nacional) as (Observatorio Astronomico Nacional)
Mueller, // G. Mueller, based on visual observations Mueller, // G. Mueller, based on visual obser
1877-91. [Expl.Suppl.1961] vations 1877-91. [Expl.Suppl.1961]
Harris, // Astronomical Almanac 1984 and later. Thes Harris, // Astronomical Almanac 1984 and lat
e give V (instrumental) magnitudes (D.L. Harris) er. These give V (instrumental) magnitudes (D.L. Harris)
UndefinedAlgorithm, UndefinedAlgorithm,
Generic // Visual magnitude based on phase angle and albedo Generic // Visual magnitude based on phase a ngle and albedo
}; };
Planet(const QString& englishName, Planet(const QString& englishName,
int flagLighting, int flagLighting,
double radius, double radius,
double oblateness, double oblateness,
Vec3f halocolor, Vec3f halocolor,
float albedo, float albedo,
const QString& texMapName, const QString& texMapName,
const QString& normalMapName, const QString& normalMapName,
skipping to change at line 156 skipping to change at line 164
virtual double getCloseViewFov(const StelCore* core) const; virtual double getCloseViewFov(const StelCore* core) const;
virtual double getSatellitesFov(const StelCore* core) const; virtual double getSatellitesFov(const StelCore* core) const;
virtual double getParentSatellitesFov(const StelCore* core) const; virtual double getParentSatellitesFov(const StelCore* core) const;
virtual float getVMagnitude(const StelCore* core) const; virtual float getVMagnitude(const StelCore* core) const;
virtual float getSelectPriority(const StelCore* core) const; virtual float getSelectPriority(const StelCore* core) const;
virtual Vec3f getInfoColor(void) const; virtual Vec3f getInfoColor(void) const;
virtual QString getType(void) const {return "Planet";} virtual QString getType(void) const {return "Planet";}
virtual Vec3d getJ2000EquatorialPos(const StelCore *core) const; virtual Vec3d getJ2000EquatorialPos(const StelCore *core) const;
virtual QString getEnglishName(void) const; virtual QString getEnglishName(void) const;
virtual QString getNameI18n(void) const; virtual QString getNameI18n(void) const;
//! Get angular semidiameter, degrees. If planet display is artifici ally enlarged (e.g. Moon upscale), value will also be increased.
virtual double getAngularSize(const StelCore* core) const; virtual double getAngularSize(const StelCore* core) const;
virtual bool hasAtmosphere(void) {return atmosphere;} virtual bool hasAtmosphere(void) {return atmosphere;}
virtual bool hasHalo(void) {return halo;} virtual bool hasHalo(void) {return halo;}
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods of SolarSystem object // Methods of SolarSystem object
//! Translate planet name using the passed translator //! Translate planet name using the passed translator
virtual void translateName(const StelTranslator &trans); virtual void translateName(const StelTranslator &trans);
// Draw the Planet // Draw the Planet
skipping to change at line 293 skipping to change at line 302
double deltaOrbitJDE; double deltaOrbitJDE;
bool orbitCached; // whether orbit calculations are c ached for drawing orbit yet bool orbitCached; // whether orbit calculations are c ached for drawing orbit yet
bool closeOrbit; // whether to connect the beginning of the orbit line to bool closeOrbit; // whether to connect the beginning of the orbit line to
// the end: good for elliptical orb its, bad for parabolic // the end: good for elliptical orb its, bad for parabolic
// and hyperbolic orbits // and hyperbolic orbits
static Vec3f orbitColor; static Vec3f orbitColor;
static void setOrbitColor(const Vec3f& oc) {orbitColor = oc;} static void setOrbitColor(const Vec3f& oc) {orbitColor = oc;}
static const Vec3f& getOrbitColor() {return orbitColor;} static const Vec3f& getOrbitColor() {return orbitColor;}
static Vec3f orbitMajorPlanetsColor;
static void setMajorPlanetOrbitColor(const Vec3f& oc) { orbitMajorPl
anetsColor = oc;}
static const Vec3f& getMajorPlanetOrbitColor() {return orbitMajorPla
netsColor;}
static Vec3f orbitMoonsColor;
static void setMoonOrbitColor(const Vec3f& oc) { orbitMoonsColor = o
c;}
static const Vec3f& getMoonOrbitColor() {return orbitMoonsColor;}
static Vec3f orbitMinorPlanetsColor;
static void setMinorPlanetOrbitColor(const Vec3f& oc) { orbitMinorPl
anetsColor = oc;}
static const Vec3f& getMinorPlanetOrbitColor() {return orbitMinorPla
netsColor;}
static Vec3f orbitDwarfPlanetsColor;
static void setDwarfPlanetOrbitColor(const Vec3f& oc) { orbitDwarfPl
anetsColor = oc;}
static const Vec3f& getDwarfPlanetOrbitColor() {return orbitDwarfPla
netsColor;}
static Vec3f orbitCubewanosColor;
static void setCubewanoOrbitColor(const Vec3f& oc) { orbitCubewanosC
olor = oc;}
static const Vec3f& getCubewanoOrbitColor() {return orbitCubewanosCo
lor;}
static Vec3f orbitPlutinosColor;
static void setPlutinoOrbitColor(const Vec3f& oc) { orbitPlutinosCol
or = oc;}
static const Vec3f& getPlutinoOrbitColor() {return orbitPlutinosColo
r;}
static Vec3f orbitScatteredDiscObjectsColor;
static void setScatteredDiscObjectOrbitColor(const Vec3f& oc) { orbi
tScatteredDiscObjectsColor = oc;}
static const Vec3f& getScatteredDiscObjectOrbitColor() {return orbit
ScatteredDiscObjectsColor;}
static Vec3f orbitOortCloudObjectsColor;
static void setOortCloudObjectOrbitColor(const Vec3f& oc) { orbitOor
tCloudObjectsColor = oc;}
static const Vec3f& getOortCloudObjectOrbitColor() {return orbitOort
CloudObjectsColor;}
static Vec3f orbitCometsColor;
static void setCometOrbitColor(const Vec3f& oc) { orbitCometsColor =
oc;}
static const Vec3f& getCometOrbitColor() {return orbitCometsColor;}
static Vec3f orbitMercuryColor;
static void setMercuryOrbitColor(const Vec3f& oc) { orbitMercuryColo
r = oc;}
static const Vec3f& getMercuryOrbitColor() {return orbitMercuryColor
;}
static Vec3f orbitVenusColor;
static void setVenusOrbitColor(const Vec3f& oc) { orbitVenusColor =
oc;}
static const Vec3f& getVenusOrbitColor() {return orbitVenusColor;}
static Vec3f orbitEarthColor;
static void setEarthOrbitColor(const Vec3f& oc) { orbitEarthColor =
oc;}
static const Vec3f& getEarthOrbitColor() {return orbitEarthColor;}
static Vec3f orbitMarsColor;
static void setMarsOrbitColor(const Vec3f& oc) { orbitMarsColor = oc
;}
static const Vec3f& getMarsOrbitColor() {return orbitMarsColor;}
static Vec3f orbitJupiterColor;
static void setJupiterOrbitColor(const Vec3f& oc) { orbitJupiterColo
r = oc;}
static const Vec3f& getJupiterOrbitColor() {return orbitJupiterColor
;}
static Vec3f orbitSaturnColor;
static void setSaturnOrbitColor(const Vec3f& oc) { orbitSaturnColor
= oc;}
static const Vec3f& getSaturnOrbitColor() {return orbitSaturnColor;}
static Vec3f orbitUranusColor;
static void setUranusOrbitColor(const Vec3f& oc) { orbitUranusColor
= oc;}
static const Vec3f& getUranusOrbitColor() {return orbitUranusColor;}
static Vec3f orbitNeptuneColor;
static void setNeptuneOrbitColor(const Vec3f& oc) { orbitNeptuneColo
r = oc;}
static const Vec3f& getNeptuneOrbitColor() {return orbitNeptuneColor
;}
static bool permanentDrawingOrbits; static bool permanentDrawingOrbits;
static PlanetOrbitColorStyle orbitColorStyle;
//! Return the list of planets which project some shadow on this pla net //! Return the list of planets which project some shadow on this pla net
QVector<const Planet*> getCandidatesForShadow() const; QVector<const Planet*> getCandidatesForShadow() const;
protected: protected:
static StelTextureSP texEarthShadow; // for lunar eclipses static StelTextureSP texEarthShadow; // for lunar eclipses
void computeModelMatrix(Mat4d &result) const; void computeModelMatrix(Mat4d &result) const;
Vec3f getCurrentOrbitColor();
// Return the information string "ready to print" :) // Return the information string "ready to print" :)
QString getSkyLabel(const StelCore* core) const; QString getSkyLabel(const StelCore* core) const;
// Draw the 3d model. Call the proper functions if there are rings e tc.. // Draw the 3d model. Call the proper functions if there are rings e tc..
void draw3dModel(StelCore* core, StelProjector::ModelViewTranformP t ransfo, float screenSz, bool drawOnlyRing=false); void draw3dModel(StelCore* core, StelProjector::ModelViewTranformP t ransfo, float screenSz, bool drawOnlyRing=false);
// Draw the 3D sphere // Draw the 3D sphere
void drawSphere(StelPainter* painter, float screenSz, bool drawOnlyR ing=false); void drawSphere(StelPainter* painter, float screenSz, bool drawOnlyR ing=false);
// Draw the circle and name of the Planet // Draw the circle and name of the Planet
 End of changes. 8 change blocks. 
20 lines changed or deleted 127 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/