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

Landscape Class Reference

Store and manages the displaying of the Landscape. More...

#include <Landscape.hpp>

List of all members.

Classes

struct  landscapeTexCoord

Public Member Functions

 Landscape (float _radius=2.f)
virtual void load (const QSettings &landscapeIni, const QString &landscapeId)=0
virtual void draw (StelCore *core, class StelRenderer *renderer)=0
 Draw the landscape.
void update (double deltaTime)
void setBrightness (const float b)
 Set the brightness of the landscape.
void setFlagShow (const bool b)
 Set whether landscape is displayed (does not concern fog).
bool getFlagShow () const
 Get whether landscape is displayed (does not concern fog).
void setFlagShowFog (const bool b)
 Set whether fog is displayed.
bool getFlagShowFog () const
 Get whether fog is displayed.
QString getName () const
 Get landscape name.
QString getAuthorName () const
 Get landscape author name.
QString getDescription () const
 Get landscape description.
const StelLocationgetLocation () const
 Return the associated location or NULL.
int getDefaultBortleIndex () const
 Return default Bortle index (light pollution value) or -1 (unknown/no change).
int getDefaultFogSetting () const
 Return default fog setting (0/1) or -1 (no change).
float getDefaultAtmosphericExtinction () const
 Return default atmosperic extinction, mag/airmass, or -1 (no change).
float getDefaultAtmosphericTemperature () const
 Return default atmospheric temperature, for refraction computation, or -1000 for "unknown/no change".
float getDefaultAtmosphericPressure () const
 Return default atmospheric temperature, for refraction computation.
void setZRotation (float d)
 Set the z-axis rotation (offset from original value when rotated.

Protected Member Functions

void loadCommon (const QSettings &landscapeIni, const QString &landscapeId)
 Load attributes common to all landscapes.
const QString getTexturePath (const QString &basename, const QString &landscapeId)
 search for a texture in landscape directory, else global textures directory

Protected Attributes

const float radius
QString name
float skyBrightness
float nightBrightness
bool validLandscape
LinearFader landFader
LinearFader fogFader
QString author
QString description
int rows
int cols
int defaultBortleIndex
int defaultFogSetting
double defaultExtinctionCoefficient
double defaultTemperature
double defaultPressure
StelLocation location
float angleRotateZ
float angleRotateZOffset

Detailed Description

Store and manages the displaying of the Landscape.

Don't use this class direcly, use the LandscapeMgr.

Definition at line 42 of file Landscape.hpp.


Member Function Documentation

virtual void Landscape::draw ( StelCore core,
class StelRenderer renderer 
) [pure virtual]

Draw the landscape.

Parameters:
core The StelCore object.
renderer The renderer to draw with.

Implemented in LandscapeOldStyle, LandscapeFisheye, and LandscapeSpherical.

QString Landscape::getAuthorName (  )  const [inline]

Get landscape author name.

Definition at line 75 of file Landscape.hpp.

float Landscape::getDefaultAtmosphericExtinction (  )  const [inline]

Return default atmosperic extinction, mag/airmass, or -1 (no change).

Definition at line 86 of file Landscape.hpp.

float Landscape::getDefaultAtmosphericPressure (  )  const [inline]

Return default atmospheric temperature, for refraction computation.

returns -1 to signal "standard conditions", or -2 for "unknown/invalid/no change"

Definition at line 91 of file Landscape.hpp.

float Landscape::getDefaultAtmosphericTemperature (  )  const [inline]

Return default atmospheric temperature, for refraction computation, or -1000 for "unknown/no change".

Definition at line 88 of file Landscape.hpp.

int Landscape::getDefaultBortleIndex (  )  const [inline]

Return default Bortle index (light pollution value) or -1 (unknown/no change).

Definition at line 82 of file Landscape.hpp.

int Landscape::getDefaultFogSetting (  )  const [inline]

Return default fog setting (0/1) or -1 (no change).

Definition at line 84 of file Landscape.hpp.

QString Landscape::getDescription (  )  const [inline]

Get landscape description.

Definition at line 77 of file Landscape.hpp.

bool Landscape::getFlagShow (  )  const [inline]

Get whether landscape is displayed (does not concern fog).

Definition at line 67 of file Landscape.hpp.

bool Landscape::getFlagShowFog (  )  const [inline]

Get whether fog is displayed.

Definition at line 71 of file Landscape.hpp.

const StelLocation& Landscape::getLocation (  )  const [inline]

Return the associated location or NULL.

Definition at line 80 of file Landscape.hpp.

QString Landscape::getName (  )  const [inline]

Get landscape name.

Definition at line 73 of file Landscape.hpp.

const QString Landscape::getTexturePath ( const QString &  basename,
const QString &  landscapeId 
) [protected]

search for a texture in landscape directory, else global textures directory

Parameters:
basename The name of a texture file, e.g. "fog.png"
landscapeId The landscape ID (directory name) to which the texture belongs
Exceptions:
misc possibility of throwing "file not found" exceptions
void Landscape::loadCommon ( const QSettings &  landscapeIni,
const QString &  landscapeId 
) [protected]

Load attributes common to all landscapes.

Parameters:
landscapeIni A reference to an existant QSettings object which describes the landscape
landscapeId The name of the directory for the landscape files (e.g. "ocean")
void Landscape::setBrightness ( const float  b  )  [inline]

Set the brightness of the landscape.

Definition at line 62 of file Landscape.hpp.

void Landscape::setFlagShow ( const bool  b  )  [inline]

Set whether landscape is displayed (does not concern fog).

Definition at line 65 of file Landscape.hpp.

void Landscape::setFlagShowFog ( const bool  b  )  [inline]

Set whether fog is displayed.

Definition at line 69 of file Landscape.hpp.

void Landscape::setZRotation ( float  d  )  [inline]

Set the z-axis rotation (offset from original value when rotated.

Definition at line 94 of file Landscape.hpp.


The documentation for this class was generated from the following file:
Generated on Thu Jan 31 14:05:43 2013 for Stellarium by  doxygen 1.6.3