An object representing a geographic location. More...
#include <Location.h>
Public Member Functions | |
| Location () | |
| Default constructor. | |
| void | SetLatitude (double decimalLatitude) |
| Set the simulated latitude. | |
| double | GetLatitude () const |
| Retrieves the simulated latitude in decimal degrees form. | |
| void | SetLongitude (double decimalLongitude) |
| Set the simulated longitude. | |
| double | GetLongitude () const |
| Retrieves the simulated longitude in decimal degrees. | |
| void | SetAltitude (double metersAboveMeanSeaLevel) |
| Sets the simulated eyepoint altitude in meters above mean sea level. | |
| double | GetAltitude () const |
| Retrives the currently simulated altitude above mean sea level, in meters. | |
| bool | Serialize (std::ostream &stream) |
| Flattens this object and everything in it to a stream buffer. | |
| bool | Unserialize (std::istream &stream) |
| Restores this object from the stream created using Serialize(). | |
An object representing a geographic location.
A Location object must be passed to AtmosphericConditions::SetLocation() to specify the location you wish to simulate. This affects the position of the sun and moon in the sky, which in turn affects your scene's lighting. Be sure that your Location is consistent with the time zone specified in LocalTime::SetTimeZone().
| SilverLining::Location::Location | ( | ) |
Default constructor.
Creates a Location object with default settings. Defaults will be read from the SilverLining.config file if this is constructed after calling Atmosphere::Initialize()
| double SilverLining::Location::GetAltitude | ( | ) | const [inline] |
Retrives the currently simulated altitude above mean sea level, in meters.
| double SilverLining::Location::GetLatitude | ( | ) | const [inline] |
| double SilverLining::Location::GetLongitude | ( | ) | const [inline] |
| bool SilverLining::Location::Serialize | ( | std::ostream & | stream | ) |
Flattens this object and everything in it to a stream buffer.
| void SilverLining::Location::SetAltitude | ( | double | metersAboveMeanSeaLevel | ) | [inline] |
Sets the simulated eyepoint altitude in meters above mean sea level.
This altitude is only used for astronomical calculations and thereby doesn't have much of an affect on the simulation. Therefore it is not necessary to call SetAltitude() whenever your camera position changes, nor is it particularly important to set this to anything other than zero.
| void SilverLining::Location::SetLatitude | ( | double | decimalLatitude | ) | [inline] |
Set the simulated latitude.
| decimalLatitude | The latitude in decimal degrees form (ie, 45.87). North is positive. |
| void SilverLining::Location::SetLongitude | ( | double | decimalLongitude | ) | [inline] |
Set the simulated longitude.
| decimalLongitude | The longitude in decimal degrees form (ie, -122.78). East is positive. |
1.6.2