24 #include <QVariantMap>
26 #include "StelFader.hpp"
27 #include "StelObjectModule.hpp"
40 static const int RCMAG_TABLE_SIZE = 4096;
83 Q_PROPERTY(
bool flagStarsDisplayed
86 NOTIFY starsDisplayedChanged)
87 Q_PROPERTY(
bool flagLabelsDisplayed
90 NOTIFY starLabelsDisplayedChanged)
112 virtual void update(
double deltaTime) {labelsFader.update((
int)(deltaTime*1000)); starsFader.update((
int)(deltaTime*1000));}
136 virtual QStringList
listMatchingObjectsI18n(
const QString& objPrefix,
int maxNbItem=5,
bool useStartOfWords=
false)
const;
142 virtual QStringList
listMatchingObjects(
const QString& objPrefix,
int maxNbItem=5,
bool useStartOfWords=
false)
const;
145 virtual QStringList listAllObjectsByType(
const QString& objType,
bool inEnglish)
const;
146 virtual QString getName()
const {
return "Stars"; }
184 static bool getFlagSciNames(
void) {
return flagSciNames;}
223 static QString getCommonEnglishName(
int hip);
280 static QString convertToSpectralType(
int index);
281 static QString convertToComponentIds(
int index);
283 QVariantList getCatalogsDescription()
const {
return catalogsDescription;}
291 void setStelStyle(
const QString& section);
298 void updateSkyCulture(
const QString& skyCultureDir);
301 void starLabelsDisplayedChanged(
const bool displayed);
302 void starsDisplayedChanged(
const bool displayed);
306 void setCheckFlag(
const QString& catalogId,
bool b);
308 void copyDefaultConfigFile();
314 int loadCommonNames(
const QString& commonNameFile);
319 void loadSciNames(
const QString& sciNameFile);
323 void loadGcvs(
const QString& GcvsFile);
327 void loadCrossIndex(
const QString& crossIndexFile);
331 int getMaxSearchLevel()
const;
334 void loadData(QVariantMap starsConfigFile);
346 int maxGeodesicGridLevel;
347 int lastMaxSearchLevel;
350 QVector<ZoneArray*> gridLevels;
351 static void initTriangleFunc(
int lev,
int index,
357 reinterpret_cast<StarMgr*
>(context)->initTriangle(lev, index, c0, c1, c2);
360 void initTriangle(
int lev,
int index,
367 static QHash<int, QString> commonNamesMap;
368 static QHash<int, QString> commonNamesMapI18n;
369 static QMap<QString, int> commonNamesIndexI18n;
370 static QMap<QString, int> commonNamesIndex;
372 static QHash<int, QString> sciNamesMapI18n;
373 static QMap<QString, int> sciNamesIndexI18n;
375 static QHash<int, QString> sciAdditionalNamesMapI18n;
376 static QMap<QString, int> sciAdditionalNamesIndexI18n;
378 static QHash<int, varstar> varStarsMapI18n;
379 static QMap<QString, int> varStarsIndexI18n;
381 static QHash<int, int> saoStarsMap;
382 static QMap<int, int> saoStarsIndex;
383 static QHash<int, int> hdStarsMap;
384 static QMap<int, int> hdStarsIndex;
387 static bool flagSciNames;
394 QString starConfigFileFullPath;
395 QVariantMap starSettings;
396 QVariantList catalogsDescription;
400 #endif // _STARMGR_HPP_
static QString getSciName(int hip)
Get the (translated) scientific name for a star with a specified Hipparcos catalogue number...
static double getGcvsEpoch(int hip)
Get Epoch for maximum light for a variable star with a specified Hipparcos catalogue number...
bool getFlagStars(void) const
Get display flag for Stars.
static int getGcvsMM(int hip)
Get the rising time or duration of eclipse for a variable star with a specified Hipparcos catalogue n...
int Mm
Period of the variable star (days)
StelObjectP searchHP(int hip) const
Search by Hipparcos catalogue number.
double epoch
The photometric system for magnitudes.
Container for Hipparcos information.
virtual void init()
Initialize the StarMgr.
float min2mag
First minimum magnitude or amplitude.
float min1mag
Magnitude flag code.
virtual StelObjectP searchByName(const QString &name) const
Return the matching star if exists or NULL.
Implementation of StelFader which implements a linear transition.
float maxmag
Type of variability.
static QString getCrossIndexDesignations(int hip)
Get the cross-index designations for a star with a specified Hipparcos catalogue number.
The base abstract class for sky objects used in Stellarium like Stars, Planets, Constellations etc...
static QString getSciAdditionalName(int hip)
Get the (translated) additional scientific name for a star with a specified Hipparcos catalogue numbe...
A templatized 3d vector compatible with openGL.
Define the StelTextureSP type.
Vec3f getLabelColor(void) const
Get the current color used to label bright stars.
double period
Epoch for maximum light (Julian days)
QString vtype
GCVS designation.
Manages all ZoneData structures of a given StelGeodesicGrid level.
static float getGcvsMaxMagnitude(int hip)
Get the magnitude at maximum brightness for a variable star with a specified Hipparcos catalogue numb...
virtual QStringList listMatchingObjects(const QString &objPrefix, int maxNbItem=5, bool useStartOfWords=false) const
Find and return the list of at most maxNbItem objects auto-completing the passed object English name...
static double getGcvsPeriod(int hip)
Get the period for a variable star with a specified Hipparcos catalogue number.
void setLabelColor(const Vec3f &c)
Set the color used to label bright stars.
QString stype
Rising time or duration of eclipse (%)
Main class for Stellarium core processing.
bool getFlagLabels(void) const
Get display flag for Star names (labels).
void setFlagStars(bool b)
Set display flag for Stars.
static int getGcvsMagnitudeFlag(int hip)
Get the magnitude flag code for a variable star with a specified Hipparcos catalogue number...
Specialization of StelModule which manages a collection of StelObject.
virtual void draw(StelCore *core)
Draw the stars and the star selection indicator if necessary.
void setFontSize(float newFontSize)
Define font size to use for star names display.
bool checkAndLoadCatalog(const QVariantMap &m)
Try to load the given catalog, even if it is marched as unchecked.
void setLabelsAmount(float a)
Set the amount of star labels.
Converts tones in function of the eye adaptation to luminance.
virtual QStringList listMatchingObjectsI18n(const QString &objPrefix, int maxNbItem=5, bool useStartOfWords=false) const
Find and return the list of at most maxNbItem objects auto-completing the passed object I18n name...
float getLabelsAmount(void) const
Get the amount of star labels.
Provides functions for performing openGL drawing operations.
Provide the main interface to all operations of projecting coordinates from sky to screen...
virtual QList< StelObjectP > searchAround(const Vec3d &v, double limitFov, const StelCore *core) const
Return a list containing the stars located inside the limFov circle around position v...
virtual void update(double deltaTime)
Update any time-dependent features.
Stores the star catalogue data.
static QString getGcvsVariabilityType(int hip)
Get the type of variability for a variable star with a specified Hipparcos catalogue number...
Manage the selection and queries on one or more StelObjects.
StelModuleActionName
Define the possible action for which an order is defined.
static float getGcvsMinMagnitude(int hip, bool firstMinimumFlag=true)
Get the minimum magnitude or amplitude for a variable star with a specified Hipparcos catalogue numbe...
virtual QStringList listAllObjects(bool inEnglish) const
static QString getGcvsName(int hip)
Get the (translated) scientific name for a variable star with a specified Hipparcos catalogue number...
int mflag
Magnitude at maximum brightness.
static QString getCommonName(int hip)
Get the (translated) common name for a star with a specified Hipparcos catalogue number.
Define the StelProjectorP type.
QSharedPointer< StelTexture > StelTextureSP
Use shared pointer to simplify memory managment.
void setFlagLabels(bool b)
Set display flag for Star names (labels).
virtual double getCallOrder(StelModuleActionName actionName) const
Used to determine the order in which the various StelModules are drawn.
static void setFlagSciNames(bool f)
Show scientific or catalog names on stars without common names.
virtual StelObjectP searchByNameI18n(const QString &nameI18n) const
Return the matching Stars object's pointer if exists or NULL.
QString photosys
Second minimum magnitude or amplitude.
static QString getGcvsPhotometricSystem(int hip)
Get the photometric system for a variable star with a specified Hipparcos catalogue number...