LandscapeMgr.hpp   LandscapeMgr.hpp 
skipping to change at line 105 skipping to change at line 105
Landscape* createFromFile(const QString& landscapeFile, const QStrin g& landscapeId); Landscape* createFromFile(const QString& landscapeFile, const QStrin g& landscapeId);
public slots: public slots:
//////////////////////////////////////////////////////////////////// /////// //////////////////////////////////////////////////////////////////// ///////
// Methods callable from script and GUI // Methods callable from script and GUI
//! Retrieve list of the names of all the available landscape in the //! Retrieve list of the names of all the available landscape in the
//! file search path sub-directories of the landscape area //! file search path sub-directories of the landscape area
//! @return the names of the landscapes, which are the values of the name parameter in the landscape.ini files //! @return the names of the landscapes, which are the values of the name parameter in the landscape.ini files
QStringList getAllLandscapeNames() const; QStringList getAllLandscapeNames() const;
//! Retrieve list of the names of all the available landscape in the
//! file search path sub-directories of the landscape area
//! @return the names of the landscapes, which are the values of the
name parameter in the landscape.ini files
QStringList getAllLandscapeIDs() const;
//! Get the current landscape ID. //! Get the current landscape ID.
const QString& getCurrentLandscapeID() const {return currentLandscap eID;} const QString& getCurrentLandscapeID() const {return currentLandscap eID;}
//! Change the current landscape to the landscape with the ID specif ied. //! Change the current landscape to the landscape with the ID specif ied.
//! @param id the ID of the new landscape //! @param id the ID of the new landscape
//! @return false if the new landscape could not be set (e.g. no lan //! @param inThread should be false when this is called from a scrip
dscape of that ID was found). True on success. t or a thread outside the main
bool setCurrentLandscapeID(const QString& id); //! program thread. Note that if inThread is false, the return valu
e will always be true. The
//! return value may be retrieved asynchronously by connecting the
//! requestCompleteSetCurrentLandscapeID signal to the calling code.
//! @return false if the new landscape could not be set (e.g. no lan
dscape of that ID was found).
//! True on success or if inThread == false.
bool setCurrentLandscapeID(const QString& id, bool inThread=false);
//! Get the current landscape name.
QString getCurrentLandscapeName() const;
//! Change the current landscape to the landscape with the name spec
ified.
//! @param name the name of the new landscape, as found in the lands
cape:name key of the landscape.ini file.
//! @param inThread should be false when this is called from a scrip
t or a thread outside the main
//! program thread. Note that if inThread is false, the return valu
e will always be true. The
//! return value may be retrieved asynchronously by connecting the
//! requestCompleteSetCurrentLandscapeID signal to the calling code.
//! @return false if the new landscape could not be set (e.g. no lan
dscape of that ID was found).
//! True on success or if inThread == false.
bool setCurrentLandscapeName(const QString& name, bool inThread=fals
e);
//! Get the default landscape ID. //! Get the default landscape ID.
const QString& getDefaultLandscapeID() const {return defaultLandscap eID;} const QString& getDefaultLandscapeID() const {return defaultLandscap eID;}
//! Change the default landscape to the landscape with the ID specif ied. //! Change the default landscape to the landscape with the ID specif ied.
//! @param id the ID of the landscape to use by default //! @param id the ID of the landscape to use by default
//! @return false if the new landscape could not be set (e.g. no lan dscape of that ID was found). True on success. //! @return false if the new landscape could not be set (e.g. no lan dscape of that ID was found). True on success.
bool setDefaultLandscapeID(const QString& id); bool setDefaultLandscapeID(const QString& id);
//! Get the current landscape name.
QString getCurrentLandscapeName() const;
//! Change the current landscape to the landscape with the name spec
ified.
//! @param name the name of the new landscape, as found in the lands
cape:name key of the landscape.ini file.
//! @return false if the new landscape could not be set (e.g. no lan
dscape of that name was found). True on success.
bool setCurrentLandscapeName(const QString& name);
//! Return a pseudo HTML formated string with all informations on th e current landscape //! Return a pseudo HTML formated string with all informations on th e current landscape
QString getCurrentLandscapeHtmlDescription() const; QString getCurrentLandscapeHtmlDescription() const;
//! Get flag for displaying Landscape. //! Get flag for displaying Landscape.
bool getFlagLandscape() const; bool getFlagLandscape() const;
//! Set flag for displaying Landscape. //! Set flag for displaying Landscape.
void setFlagLandscape(bool b); void setFlagLandscape(bool b);
//! Get flag for displaying Fog. //! Get flag for displaying Fog.
bool getFlagFog() const; bool getFlagFog() const;
skipping to change at line 167 skipping to change at line 181
void setFlagAtmosphere(bool b); void setFlagAtmosphere(bool b);
//! Get atmosphere fade duration in s. //! Get atmosphere fade duration in s.
float getAtmosphereFadeDuration() const; float getAtmosphereFadeDuration() const;
//! Set atmosphere fade duration in s. //! Set atmosphere fade duration in s.
void setAtmosphereFadeDuration(float f); void setAtmosphereFadeDuration(float f);
//! Set the light pollution following the Bortle Scale //! Set the light pollution following the Bortle Scale
void setAtmosphereBortleLightPollution(int bIndex); void setAtmosphereBortleLightPollution(int bIndex);
//! Set the rotation of the landscape about the z-axis.
//! This is intended for special uses such as when the landscape con
sists of
//! a vehicle which might change orientation over time (e.g. a ship)
.
//! @param d the rotation angle in degrees as an offset from the ori
ginally loaded value.
void setZRotation(double d);
signals:
// used for multi-threaded mode callbacks
void requestSetCurrentLandscapeID(const QString& id);
void requestCompleteSetCurrentLandscapeID(bool success);
void requestSetCurrentLandscapeName(const QString& name);
void requestCompleteSetCurrentLandscapeName(bool success);
private slots:
// Callbacks for threaded mode landscape setting which use signals
//! Change the current landscape to the landscape with the ID specif
ied.
//! @param id the ID of the new landscape
//! @return false if the new landscape could not be set (e.g. no lan
dscape of that ID was found). True on success.
bool doSetCurrentLandscapeID(const QString& id);
//! Change the current landscape to the landscape with the name spec
ified.
//! @param name the name of the new landscape, as found in the lands
cape:name key of the landscape.ini file.
//! @return false if the new landscape could not be set (e.g. no lan
dscape of that name was found). True on success.
bool doSetCurrentLandscapeName(const QString& name);
private: private:
//! Get light pollution luminance level. //! Get light pollution luminance level.
double getAtmosphereLightPollutionLuminance() const; double getAtmosphereLightPollutionLuminance() const;
//! Set light pollution luminance level. //! Set light pollution luminance level.
void setAtmosphereLightPollutionLuminance(double f); void setAtmosphereLightPollutionLuminance(double f);
//! For a given landscape name, return the landscape ID. //! For a given landscape name, return the landscape ID.
//! This takes a name of the landscape, as described in the landscap e:name item in the //! This takes a name of the landscape, as described in the landscap e:name item in the
//! landscape.ini, and returns the landscape ID which corresponds to that name. //! landscape.ini, and returns the landscape ID which corresponds to that name.
QString nameToID(const QString& name); QString nameToID(const QString& name);
 End of changes. 4 change blocks. 
13 lines changed or deleted 66 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/