![]() |
Stellarium 0.12.4
|
Classes | |
struct | SharedPlanetGraphics |
Stores graphics data that is shared between planets and must be initialized by a StelRenderer. More... | |
struct | Vertex2D |
A simple 2D vertex with only a position. More... | |
Public Member Functions | |
Planet (const QString &englishName, int flagLighting, double radius, double oblateness, Vec3f color, float albedo, const QString &texMapName, posFuncType _coordFunc, void *userDataPtr, OsculatingFunctType *osculatingFunc, bool closeOrbit, bool hidden, bool hasAtmosphere, const QString &pType) | |
virtual QString | getInfoString (const StelCore *core, const InfoStringGroup &flags) const |
Get a string with data about the Planet. More... | |
virtual double | getCloseViewFov (const StelCore *core) const |
Return the best FOV in degree to use for a close view of the object. More... | |
virtual double | getSatellitesFov (const StelCore *core) const |
Return the best FOV in degree to use for a global view of the object satellite system (if there are satellites) More... | |
virtual double | getParentSatellitesFov (const StelCore *core) const |
virtual float | getVMagnitude (const StelCore *core, bool withExtinction=false) const |
Return object's apparent V magnitude as seen from observer. More... | |
virtual float | getSelectPriority (const StelCore *core) const |
Return a priority value which is used to discriminate objects by priority As for magnitudes, the lower is the higher priority. More... | |
virtual Vec3f | getInfoColor (void) const |
Get a color used to display info about the object. More... | |
virtual QString | getType (void) const |
Return object's type. It should be the name of the class. More... | |
virtual Vec3d | getJ2000EquatorialPos (const StelCore *core) const |
Get observer-centered equatorial coordinates at equinox J2000. More... | |
virtual QString | getEnglishName (void) const |
Return object's name in english. More... | |
virtual QString | getNameI18n (void) const |
Return translated object's name. More... | |
virtual double | getAngularSize (const StelCore *core) const |
Return the angular radius of a circle containing the object as seen from the observer with the circle center assumed to be at getJ2000EquatorialPos(). More... | |
virtual bool | hasAtmosphere (void) |
virtual void | translateName (StelTranslator &trans) |
Translate planet name using the passed translator. More... | |
void | draw (StelCore *core, class StelRenderer *renderer, float maxMagLabels, const QFont &planetNameFont, SharedPlanetGraphics &planetGraphics) |
Draw the Planet. More... | |
double | getRadius (void) const |
Get the radius of the planet in AU. More... | |
double | getSiderealDay (void) const |
Get duration of sidereal day. More... | |
double | getSiderealPeriod (void) const |
Get duration of sidereal year. More... | |
double | getMeanSolarDay (void) const |
Get duration of mean solar day. More... | |
const QString & | getTextMapName () const |
double | getSiderealTime (double jd) const |
Mat4d | getRotEquatorialToVsop87 (void) const |
void | setRotEquatorialToVsop87 (const Mat4d &m) |
const RotationElements & | getRotationElements (void) const |
void | computePositionWithoutOrbits (const double date) |
void | computePosition (const double date) |
void | computeTransMatrix (double date) |
void | computeModelMatrix (Mat4d &result) const |
double | getPhaseAngle (const Vec3d &obsPos) const |
double | getElongation (const Vec3d &obsPos) const |
double | getSpheroidAngularSize (const StelCore *core) const |
float | getPhase (const Vec3d &obsPos) const |
void | setRotationElements (float _period, float _offset, double _epoch, float _obliquity, float _ascendingNode, float _precessionRate, double _siderealPeriod) |
double | getRotAscendingnode (void) const |
double | getRotObliquity (void) const |
Vec3d | getEclipticPos () const |
Get the Planet position in the parent Planet ecliptic coordinate in AU. More... | |
Vec3d | getHeliocentricEclipticPos () const |
Vec3d | getHeliocentricPos (Vec3d) const |
void | setHeliocentricEclipticPos (const Vec3d &pos) |
double | computeDistance (const Vec3d &obsHelioPos) |
double | getDistance (void) const |
void | setRings (Ring *r) |
void | setSphereScale (float s) |
float | getSphereScale (void) const |
const QSharedPointer< Planet > | getParent (void) const |
void | update (int deltaTime) |
void | setFlagHints (bool b) |
bool | getFlagHints (void) const |
void | setFlagLabels (bool b) |
bool | getFlagLabels (void) const |
void | setFlagOrbits (bool b) |
bool | getFlagOrbits (void) const |
void | drawOrbit (const StelCore *core, class StelRenderer *renderer) |
![]() | |
Q_FLAGS (InfoStringGroup) static const InfoStringGroupFlags AllInfo | |
A pre-defined set of specifiers for the getInfoString flags argument to getInfoString. More... | |
virtual SphericalRegionP | getRegion () const |
Default implementation of the getRegion method. More... | |
Vec3d | getEquinoxEquatorialPos (const StelCore *core) const |
Get observer-centered equatorial coordinate at the current equinox The frame has it's Z axis at the planet's current rotation axis At time 2000-01-01 this frame is almost the same as J2000, but ONLY if the observer is on earth. More... | |
Vec3d | getJ2000GalacticPos (const StelCore *core) const |
Get observer-centered galactic coordinates at equinox J2000. More... | |
Vec3d | getSideralPosGeometric (const StelCore *core) const |
Get observer-centered hour angle + declination (at current equinox) It is the geometric position, i.e. More... | |
Vec3d | getSideralPosApparent (const StelCore *core) const |
Get observer-centered hour angle + declination (at current equinox) It is the apparent position, i.e. More... | |
Vec3d | getAltAzPosGeometric (const StelCore *core) const |
Get observer-centered alt/az position It is the geometric position, i.e. More... | |
Vec3d | getAltAzPosApparent (const StelCore *core) const |
Get observer-centered alt/az position It is the apparent position, i.e. More... | |
Vec3d | getAltAzPosAuto (const StelCore *core) const |
Get observer-centered alt/az position It is the automatic position, i.e. More... | |
Static Public Member Functions | |
static void | setLabelColor (const Vec3f &lc) |
static const Vec3f & | getLabelColor (void) |
static void | setOrbitColor (const Vec3f &oc) |
static const Vec3f & | getOrbitColor () |
Public Attributes | |
StelVertexBuffer< Vertex2D > * | orbitVertices |
Vertex buffer used to draw the orbit. More... | |
LinearFader | orbitFader |
Vec3d | orbit [ORBIT_SEGMENTS+1] |
Vec3d | orbitP [ORBIT_SEGMENTS+1] |
double | lastOrbitJD |
double | deltaJD |
double | deltaOrbitJD |
bool | orbitCached |
bool | closeOrbit |
Static Public Attributes | |
static Vec3f | orbitColor |
![]() | |
static const InfoStringGroupFlags | ShortInfo = (InfoStringGroupFlags)(Name|CatalogNumber|Magnitude|RaDecJ2000) |
A pre-defined set of specifiers for the getInfoString flags argument to getInfoString. More... | |
Protected Member Functions | |
void | drawEarthShadow (StelCore *core, class StelRenderer *renderer, SharedPlanetGraphics &planetGraphics) |
QString | getSkyLabel (const StelCore *core) const |
void | draw3dModel (StelCore *core, class StelRenderer *renderer, SharedPlanetGraphics &planetGraphics, StelProjector::ModelViewTranformP transfo, float screenSz) |
Draw the 3d model. More... | |
void | drawUnlitSphere (class StelRenderer *renderer, StelProjectorP projector) |
Draw the unlit sphere model. More... | |
void | drawSphere (class StelRenderer *renderer, StelProjectorP projector, const struct StelLight *light, SharedPlanetGraphics &planetGraphics, float screenSz) |
Draw the 3D sphere. More... | |
void | drawHints (const StelCore *core, class StelRenderer *renderer, const QFont &planetNameFont, SharedPlanetGraphics &planetGraphics) |
![]() | |
QString | getPositionInfoString (const StelCore *core, const InfoStringGroup &flags) const |
Format the positional info string contain J2000/of date/altaz/hour angle positions for the object. More... | |
void | postProcessInfoString (QString &str, const InfoStringGroup &flags) const |
Apply post processing on the info string. More... | |
Protected Attributes | |
QString | englishName |
QString | nameI18 |
QString | texMapName |
RotationElements | re |
const int | flagLighting |
const double | radius |
const double | oneMinusOblateness |
Vec3d | eclipticPos |
Vec3d | screenPos |
Vec3d | previousScreenPos |
Vec3f | color |
float | albedo |
Mat4d | rotLocalToParent |
float | axisRotation |
class StelTextureNew * | texture |
Ring * | rings |
double | distance |
float | sphereScale |
double | lastJD |
posFuncType | coordFunc |
void * | userDataPtr |
OsculatingFunctType *const | osculatingFunc |
QSharedPointer< Planet > | parent |
QList< QSharedPointer< Planet > > | satellites |
LinearFader | hintFader |
LinearFader | labelsFader |
bool | flagLabels |
bool | hidden |
bool | atmosphere |
QString | pType |
class StelGeometrySphere * | unlitSphere |
Sphere used to draw the planet when lighting is disabled or when it is done in shaders. More... | |
class StelGeometrySphere * | litSphere |
Sphere used to draw the planet when lighting is enabled and shaders are not used. More... | |
Static Protected Attributes | |
static Vec3f | labelColor |
Additional Inherited Members | |
![]() | |
enum | InfoStringGroupFlags { Name = 0x00000001, CatalogNumber = 0x00000002, Magnitude = 0x00000004, RaDecJ2000 = 0x00000008, RaDecOfDate = 0x00000010, AltAzi = 0x00000020, Distance = 0x00000040, Size = 0x00000080, Extra1 = 0x00000100, Extra2 = 0x00000200, Extra3 = 0x00000400, PlainText = 0x00000800, HourAngle = 0x00001000, AbsoluteMagnitude = 0x00002000, GalCoordJ2000 = 0x00004000 } |
used as named bitfield flags as specifiers to filter results of getInfoString. More... | |
typedef QFlags < InfoStringGroupFlags > | InfoStringGroup |
Definition at line 110 of file Planet.hpp.
void Planet::draw | ( | StelCore * | core, |
class StelRenderer * | renderer, | ||
float | maxMagLabels, | ||
const QFont & | planetNameFont, | ||
SharedPlanetGraphics & | planetGraphics | ||
) |
|
protected |
Draw the 3d model.
Call the proper functions if there are rings etc. .
core | The StelCore object. |
renderer | Renderer used for drawing. |
planetGraphics | Graphics resources shared between planets, e.g. planet lighting shader. |
transfo | Modelview transform. |
screenSz | Screen size. |
|
protected |
Draw the 3D sphere.
renderer | Renderer to draw with. |
projector | Projector to project vertices. |
light | If NULL, lighting is not used. Otherwise the sphere is either generated with lighting (no shaders), or lit in shaders (if GLSL is supported). |
planetGraphics | To render the planet using a shader on the GPU if possible. |
screenSz | Screen size. |
|
protected |
Draw the unlit sphere model.
Used either when lighting is disabled or when it is done in shaders.
Called by drawSphere.
renderer | Renderer to draw with. |
projector | Projector to project the vertices. |
|
virtual |
Return the angular radius of a circle containing the object as seen from the observer with the circle center assumed to be at getJ2000EquatorialPos().
Implements StelObject.
|
virtual |
Return the best FOV in degree to use for a close view of the object.
Reimplemented from StelObject.
Vec3d Planet::getEclipticPos | ( | ) | const |
|
inlinevirtual |
|
virtual |
Get a color used to display info about the object.
Reimplemented from StelObject.
|
virtual |
Get a string with data about the Planet.
Planets support the following InfoStringGroup flags:
core | the StelCore object |
flags | a set of InfoStringGroup items to include in the return value. |
Implements StelObject.
Reimplemented in MinorPlanet, and Comet.
Get observer-centered equatorial coordinates at equinox J2000.
Implements StelObject.
double Planet::getMeanSolarDay | ( | void | ) | const |
Get duration of mean solar day.
|
inlinevirtual |
|
inline |
Get the radius of the planet in AU.
Definition at line 213 of file Planet.hpp.
|
virtual |
Return the best FOV in degree to use for a global view of the object satellite system (if there are satellites)
Reimplemented from StelObject.
|
virtual |
Return a priority value which is used to discriminate objects by priority As for magnitudes, the lower is the higher priority.
Reimplemented from StelObject.
|
inline |
Get duration of sidereal day.
Definition at line 215 of file Planet.hpp.
|
inline |
Get duration of sidereal year.
Definition at line 217 of file Planet.hpp.
|
inlinevirtual |
Return object's type. It should be the name of the class.
Implements StelObject.
Definition at line 187 of file Planet.hpp.
|
virtual |
Return object's apparent V magnitude as seen from observer.
Reimplemented from StelObject.
Reimplemented in MinorPlanet, and Comet.
|
virtual |
Translate planet name using the passed translator.
Reimplemented in MinorPlanet.
|
protected |
Sphere used to draw the planet when lighting is enabled and shaders are not used.
Definition at line 415 of file Planet.hpp.
StelVertexBuffer<Vertex2D>* Planet::orbitVertices |
Vertex buffer used to draw the orbit.
Definition at line 305 of file Planet.hpp.
|
protected |
Sphere used to draw the planet when lighting is disabled or when it is done in shaders.
Definition at line 413 of file Planet.hpp.