20 #ifndef _ASTERISMMGR_HPP_ 21 #define _ASTERISMMGR_HPP_ 24 #include "StelObjectModule.hpp" 29 #include <QStringList> 45 Q_PROPERTY(
float fontSize
48 NOTIFY fontSizeChanged)
49 Q_PROPERTY(
Vec3f linesColor
52 NOTIFY linesColorChanged)
53 Q_PROPERTY(
bool linesDisplayed
56 NOTIFY linesDisplayedChanged)
57 Q_PROPERTY(
Vec3f rayHelpersColor
60 NOTIFY rayHelpersColorChanged)
61 Q_PROPERTY(
bool rayHelpersDisplayed
64 NOTIFY rayHelpersDisplayedChanged)
65 Q_PROPERTY(
Vec3f namesColor
68 NOTIFY namesColorChanged)
69 Q_PROPERTY(
bool namesDisplayed
72 NOTIFY namesDisplayedChanged)
73 Q_PROPERTY(
int asterismLineThickness
76 NOTIFY asterismLineThicknessChanged)
77 Q_PROPERTY(
int rayHelperThickness
80 NOTIFY rayHelperThicknessChanged)
99 virtual void update(
double deltaTime);
125 virtual QStringList
listMatchingObjects(
const QString& objPrefix,
int maxNbItem=5,
bool useStartOfWords=
false,
bool inEnglish=
false)
const;
127 virtual QString
getName()
const {
return "Asterisms"; }
196 void fontSizeChanged(
const float newSize)
const;
197 void linesColorChanged(
const Vec3f & color)
const;
198 void linesDisplayedChanged(
const bool displayed)
const;
199 void namesColorChanged(
const Vec3f & color)
const;
200 void namesDisplayedChanged(
const bool displayed)
const;
201 void asterismLineThicknessChanged(
int thickness)
const;
202 void rayHelpersColorChanged(
const Vec3f & color)
const;
203 void rayHelpersDisplayedChanged(
const bool displayed)
const;
204 void rayHelperThicknessChanged(
int thickness)
const;
209 void updateSkyCulture(
const QString& skyCultureDir);
222 void loadNames(
const QString& namesFile);
227 void loadLines(
const QString& fileName);
237 Asterism* findFromAbbreviation(
const QString& abbreviation)
const;
241 std::vector<Asterism*> asterisms;
245 QString lastLoadedSkyCulture;
246 QString currentSkyCultureID;
249 bool rayHelpersDisplayed;
254 int asterismLineThickness;
255 int rayHelperThickness;
258 #endif // _ASTERISMMGR_HPP_ virtual QString getStelObjectType() const
Returns the name that will be returned by StelObject::getType() for the objects this module manages...
virtual StelObjectP searchByName(const QString &name) const
Return the matching asterism if exists or Q_NULLPTR.
void setFlagLabels(const bool displayed)
Set whether asterism names will be displayed.
void setLabelsColor(const Vec3f &color)
Set label color for names.
int getRayHelperThickness() const
Get the thickness of ray helper of the asterisms.
void setFlagLines(const bool displayed)
Set whether asterism lines will be displayed.
The base abstract class for sky objects used in Stellarium like Stars, Planets, Constellations etc...
virtual QList< StelObjectP > searchAround(const Vec3d &v, double limitFov, const StelCore *core) const
Search for StelObject in an area around a specifid point.
Vec3f getLabelsColor() const
Get label color for names.
void setFontSize(const float newFontSize)
Set the font size used for asterism names display.
void setRayHelpersColor(const Vec3f &color)
Define ray helper color.
Main class for Stellarium core processing.
int getAsterismLineThickness() const
Get the thickness of lines of the asterisms.
virtual StelObjectP searchByNameI18n(const QString &nameI18n) const
Return the matching asterism object's pointer if exists or Q_NULLPTR.
void setRayHelperThickness(const int thickness)
Set the thickness of ray helpers of the asterisms.
Specialization of StelModule which manages a collection of StelObject.
virtual void update(double deltaTime)
Updates time-varying state for each Constellation.
bool getFlagLines(void) const
Get whether asterism lines are displayed.
float getFontSize() const
Get the font size used for asterism names display.
Converts tones in function of the eye adaptation to luminance.
Vec3f getLinesColor() const
Get line color.
virtual QStringList listMatchingObjects(const QString &objPrefix, int maxNbItem=5, bool useStartOfWords=false, bool inEnglish=false) const
Find and return the list of at most maxNbItem objects auto-completing the passed object name...
Define the StelObjectP type.
Provides functions for performing openGL drawing operations.
Provide the main interface to all operations of projecting coordinates from sky to screen...
Display and manage the asterisms.
virtual QStringList listAllObjects(bool inEnglish) const
List all StelObjects.
AsterismMgr(StarMgr *stars)
Constructor.
Vec3f getRayHelpersColor() const
Get ray helper color.
The Asterism class models a grouping of stars in a Sky Culture.
virtual void init()
Initialize the AsterismMgr.
Stores the star catalogue data.
void setAsterismLineThickness(const int thickness)
Set the thickness of lines of the asterisms.
virtual QString getName() const
Gets a user-displayable name of the object category.
virtual double getCallOrder(StelModuleActionName actionName) const
Return the value defining the order of call for the given action.
StelModuleActionName
Define the possible action for which an order is defined.
virtual void draw(StelCore *core)
Draw constellation lines, art, names and boundaries.
virtual ~AsterismMgr()
Destructor.
void setLinesColor(const Vec3f &color)
Define line color.
Define the StelProjectorP type.
bool getFlagRayHelpers(void) const
Get whether ray helpers are displayed.
void setFlagRayHelpers(const bool displayed)
Set whether ray helpers will be displayed.
bool getFlagLabels(void) const
Set whether asterism names are displayed.
virtual StelObjectP searchByID(const QString &id) const
Return the StelObject with the given ID if exists or the empty StelObject if not found.