Home · All Namespaces · All Classes · Functions · Coding Style · Scripting · Plugins · File Structure

ConstellationMgr Class Reference

Display and manage the constellations. More...

#include <ConstellationMgr.hpp>

Inherits StelObjectModule.

List of all members.

Public Slots

void setArtFadeDuration (float duration)
float getArtFadeDuration () const
void setArtIntensity (double d)
double getArtIntensity () const
void setFlagArt (bool b)
bool getFlagArt (void) const
void setFlagLines (bool b)
bool getFlagLines (void) const
void setFlagBoundaries (bool b)
bool getFlagBoundaries (void) const
void setFlagLabels (bool b)
bool getFlagLabels (void) const
void setFlagIsolateSelected (bool s)
bool getFlagIsolateSelected (void) const
void setLinesColor (const Vec3f &c)
Vec3f getLinesColor () const
void setBoundariesColor (const Vec3f &c)
Vec3f getBoundariesColor () const
void setLabelsColor (const Vec3f &c)
Vec3f getLabelsColor () const
void setFontSize (double newFontSize)
double getFontSize () const

Public Member Functions

 ConstellationMgr (StarMgr *stars)
virtual ~ConstellationMgr ()
virtual void init ()
virtual void draw (StelCore *core)
virtual void update (double deltaTime)
virtual void updateI18n ()
virtual void updateSkyCulture (const QString &skyCultureDir)
virtual void selectedObjectChangeCallBack (StelModuleSelectAction action=StelModule::ReplaceSelection)
virtual void setStelStyle (const StelStyle &style)
virtual double getCallOrder (StelModuleActionName actionName) const
virtual QList< StelObjectPsearchAround (const Vec3d &v, double limitFov, const StelCore *core) const
virtual StelObjectP searchByNameI18n (const QString &nameI18n) const
virtual StelObjectP searchByName (const QString &name) const
virtual QStringList listMatchingObjectsI18n (const QString &objPrefix, int maxNbItem=5) const


Detailed Description

Display and manage the constellations.

It can display constellations lines, names, art textures and boundaries. It also supports several different sky cultures.


Constructor & Destructor Documentation

ConstellationMgr::ConstellationMgr ( StarMgr stars  ) 

Constructor.

virtual ConstellationMgr::~ConstellationMgr (  )  [virtual]

Destructor.


Member Function Documentation

virtual void ConstellationMgr::init (  )  [virtual]

Initialize the ConstellationMgr.

Reads from the configuration parser object and updates the loading bar as constellation objects are loaded for the required sky culture.

Implements StelModule.

virtual void ConstellationMgr::draw ( StelCore core  )  [virtual]

Draw constellation lines, art, names and boundaries.

Reimplemented from StelModule.

virtual void ConstellationMgr::update ( double  deltaTime  )  [virtual]

Updates time-varying state for each Constellation.

Implements StelModule.

virtual void ConstellationMgr::updateI18n (  )  [virtual]

Update i18n names from English names according to current locale, and update font for locale.

The translation is done using gettext with translated strings defined in translations.h

Reimplemented from StelModule.

virtual void ConstellationMgr::updateSkyCulture ( const QString &  skyCultureDir  )  [virtual]

Loads new constellation data and art if the SkyCulture has changed.

Parameters:
skyCultureDir the name of the directory containing the sky culture to use.

Reimplemented from StelModule.

virtual void ConstellationMgr::selectedObjectChangeCallBack ( StelModuleSelectAction  action = StelModule::ReplaceSelection  )  [virtual]

Limit the number of constellations to draw based on selected stars.

The selected objects changed, check if some stars are selected and display the matching constellations if isolateSelected mode is activated.

Parameters:
action define whether to add to, replace, or remove from the existing selection

Reimplemented from StelModule.

virtual void ConstellationMgr::setStelStyle ( const StelStyle style  )  [virtual]

Load a color scheme.

Reimplemented from StelModule.

virtual double ConstellationMgr::getCallOrder ( StelModuleActionName  actionName  )  const [virtual]

Return the value defining the order of call for the given action.

Parameters:
actionName the name of the action for which we want the call order
Returns:
the value defining the order. The closer to 0 the earlier the module's action will be called

Reimplemented from StelModule.

virtual QList<StelObjectP> ConstellationMgr::searchAround ( const Vec3d v,
double  limitFov,
const StelCore core 
) const [virtual]

Search for StelObject in an area around a specifid point.

The function searches in a disk of diameter limitFov centered on v. Only visible objects (i.e curretly displayed on screen) should be returned.

Parameters:
v equatorial position at epoch J2000.
limitFov angular diameter of the searching zone in degree.
core the core instance to use.
Returns:
the list of all the displayed objects contained in the defined zone.

Implements StelObjectModule.

virtual StelObjectP ConstellationMgr::searchByNameI18n ( const QString &  nameI18n  )  const [virtual]

Return the matching constellation object's pointer if exists or NULL.

Parameters:
nameI18n The case in-sensistive constellation name

Implements StelObjectModule.

virtual StelObjectP ConstellationMgr::searchByName ( const QString &  name  )  const [virtual]

Return the matching constellation if exists or NULL.

Parameters:
name The case in-sensistive standard program name (three letter abbreviation)

Implements StelObjectModule.

virtual QStringList ConstellationMgr::listMatchingObjectsI18n ( const QString &  objPrefix,
int  maxNbItem = 5 
) const [virtual]

Find and return the list of at most maxNbItem objects auto-completing the passed object I18n name.

Parameters:
objPrefix the case insensitive first letters of the searched object
maxNbItem the maximum number of returned object names
Returns:
a vector of matching object name by order of relevance, or an empty vector if nothing match

Implements StelObjectModule.

void ConstellationMgr::setArtFadeDuration ( float  duration  )  [slot]

Set constellation art fade duration in second.

float ConstellationMgr::getArtFadeDuration (  )  const [inline, slot]

Get constellation art fade duration in second.

void ConstellationMgr::setArtIntensity ( double  d  )  [slot]

Set constellation maximum art intensity (between 0 and 1).

double ConstellationMgr::getArtIntensity (  )  const [inline, slot]

Set constellation maximum art intensity (between 0 and 1).

void ConstellationMgr::setFlagArt ( bool  b  )  [slot]

Set whether constellation art will be displayed.

bool ConstellationMgr::getFlagArt ( void   )  const [inline, slot]

Get whether constellation art is displayed.

void ConstellationMgr::setFlagLines ( bool  b  )  [slot]

Set whether constellation path lines will be displayed.

bool ConstellationMgr::getFlagLines ( void   )  const [inline, slot]

Get whether constellation path lines are displayed.

void ConstellationMgr::setFlagBoundaries ( bool  b  )  [slot]

Set whether constellation boundaries lines will be displayed.

bool ConstellationMgr::getFlagBoundaries ( void   )  const [inline, slot]

Get whether constellation boundaries lines are displayed.

void ConstellationMgr::setFlagLabels ( bool  b  )  [slot]

Set whether constellation names will be displayed.

bool ConstellationMgr::getFlagLabels ( void   )  const [inline, slot]

Set whether constellation names are displayed.

void ConstellationMgr::setFlagIsolateSelected ( bool  s  )  [inline, slot]

Set whether selected constellation must be displayed alone.

bool ConstellationMgr::getFlagIsolateSelected ( void   )  const [inline, slot]

Get whether selected constellation is displayed alone.

void ConstellationMgr::setLinesColor ( const Vec3f c  )  [slot]

Define line color.

Vec3f ConstellationMgr::getLinesColor (  )  const [slot]

Get line color.

void ConstellationMgr::setBoundariesColor ( const Vec3f c  )  [slot]

Define boundary color.

Vec3f ConstellationMgr::getBoundariesColor (  )  const [slot]

Get current boundary color.

void ConstellationMgr::setLabelsColor ( const Vec3f c  )  [slot]

Set label color for names.

Vec3f ConstellationMgr::getLabelsColor (  )  const [slot]

Get label color for names.

void ConstellationMgr::setFontSize ( double  newFontSize  )  [slot]

Set the font size used for constellation names display.

double ConstellationMgr::getFontSize (  )  const [slot]

Get the font size used for constellation names display.


Generated on Mon Mar 22 09:55:38 2010 for Stellarium by  doxygen 1.5.5