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

NebulaMgr Class Reference

Manage a collection of nebulae. More...

#include <NebulaMgr.hpp>

Inherits StelObjectModule.

List of all members.

Public Slots

void setCirclesColor (const Vec3f &c)
const Vec3fgetCirclesColor (void) const
void setCircleScale (float scale)
float getCircleScale (void) const
void setHintsFadeDuration (float duration)
void setFlagHints (bool b)
bool getFlagHints (void) const
void setFlagShow (bool b)
bool getFlagShow (void) const
void setLabelsColor (const Vec3f &c)
const Vec3fgetLabelsColor (void) const
void setFlagDisplayNoTexture (bool b)
bool getFlagDisplayNoTexture (void) const
void setLabelsAmount (float a)
float getLabelsAmount (void) const
void setHintsAmount (float f)
float getHintsAmount (void) const

Public Member Functions

virtual void init ()
virtual void draw (StelCore *core)
virtual void update (double deltaTime)
virtual void updateI18n ()
virtual void updateSkyCulture (const QString &skyCultureDir)
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

Manage a collection of nebulae.

This class is used to display the NGC catalog with information, and textures for some of them.


Member Function Documentation

virtual void NebulaMgr::init (  )  [virtual]

Initialize the NebulaMgr object.

  • Load the font into the Nebula class, which is used to draw Nebula labels.
  • Load the texture used to draw nebula locations into the Nebula class (for those with no individual texture).
  • Load the pointer texture.
  • Set flags values from ini parser which relate to nebula display.
  • call updateI18n() to translate names.

Implements StelModule.

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

Draws all nebula objects.

Implements StelModule.

virtual void NebulaMgr::update ( double  deltaTime  )  [inline, virtual]

Update state which is time dependent.

Implements StelModule.

virtual void NebulaMgr::updateI18n (  )  [virtual]

Update i18 names from English names according to passed translator.

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

Reimplemented from StelModule.

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

Called when the sky culture is updated, so that the module can respond as appropriate.

Does nothing as there are no SkyCulture specific features in the current nebula implementation.

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

Reimplemented from StelModule.

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

Sets the colors of the Nebula labels and markers according to the values in a configuration object.

Reimplemented from StelModule.

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

Determines the order in which the various modules are drawn.

Reimplemented from StelModule.

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

Used to get a vector of objects which are near to some position.

Parameters:
v a vector representing the position in th sky around which to search for nebulae.
limitFov the field of view around the position v in which to search for nebulae.
core the StelCore to use for computations.
Returns:
an list containing the nebulae located inside the limitFov circle around position v.

Implements StelObjectModule.

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

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

Parameters:
nameI18n The case in-sensistive nebula name or NGC M catalog name : format can be M31, M 31, NGC31, NGC 31

Implements StelObjectModule.

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

Return the matching nebula if exists or NULL.

Parameters:
name The case in-sensistive standard program name

Implements StelObjectModule.

virtual QStringList NebulaMgr::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 list of matching object name by order of relevance, or an empty list if nothing match

Implements StelObjectModule.

void NebulaMgr::setCirclesColor ( const Vec3f c  )  [slot]

Set the color used to draw the nebula circles.

const Vec3f& NebulaMgr::getCirclesColor ( void   )  const [slot]

Get current value of the nebula circle color.

void NebulaMgr::setCircleScale ( float  scale  )  [slot]

Set Nebulae Hints circle scale.

float NebulaMgr::getCircleScale ( void   )  const [slot]

Get Nebulae Hints circle scale.

void NebulaMgr::setHintsFadeDuration ( float  duration  )  [inline, slot]

Set how long it takes for nebula hints to fade in and out when turned on and off.

void NebulaMgr::setFlagHints ( bool  b  )  [inline, slot]

Set flag for displaying Nebulae Hints.

bool NebulaMgr::getFlagHints ( void   )  const [inline, slot]

Get flag for displaying Nebulae Hints.

void NebulaMgr::setFlagShow ( bool  b  )  [inline, slot]

Set flag used to turn on and off Nebula rendering.

bool NebulaMgr::getFlagShow ( void   )  const [inline, slot]

Get value of flag used to turn on and off Nebula rendering.

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

Set the color used to draw nebula labels.

const Vec3f& NebulaMgr::getLabelsColor ( void   )  const [slot]

Get current value of the nebula label color.

void NebulaMgr::setFlagDisplayNoTexture ( bool  b  )  [inline, slot]

Set flag for displaying nebulae even without textures.

bool NebulaMgr::getFlagDisplayNoTexture ( void   )  const [inline, slot]

Get flag for displaying nebulae without textures.

void NebulaMgr::setLabelsAmount ( float  a  )  [inline, slot]

Set the amount of nebulae labels.

The real amount is also proportional with FOV. The limit is set in function of the nebulae magnitude

Parameters:
a the amount between 0 and 10. 0 is no labels, 10 is maximum of labels

float NebulaMgr::getLabelsAmount ( void   )  const [inline, slot]

Get the amount of nebulae labels.

The real amount is also proportional with FOV.

Returns:
the amount between 0 and 10. 0 is no labels, 10 is maximum of labels

void NebulaMgr::setHintsAmount ( float  f  )  [inline, slot]

Set the amount of nebulae hints.

The real amount is also proportional with FOV. The limit is set in function of the nebulae magnitude

Parameters:
f the amount between 0 and 10. 0 is no hints, 10 is maximum of hints

float NebulaMgr::getHintsAmount ( void   )  const [inline, slot]

Get the amount of nebulae labels.

The real amount is also proportional with FOV.

Returns:
the amount between 0 and 10. 0 is no hints, 10 is maximum of hints


Generated on Mon Mar 9 16:16:16 2009 for Stellarium by  doxygen 1.5.5