![]() |
VR-Forces Developer's Guide
|
A DtLocalEnvironmentalsControllerObject processes enviromental data for a localize weather area.
For each unique local weather area, there will be an instance of this class. Agents for this class are generally created by the DtEnvironmentStatusManager. Classes based from DtEnvironmentStateInterceptorBase use the DtEnvironmentStatusManager to send local environmental weather changes/data to this class via the agents.
This class will initiate and control local clouds and a weather area object (DtWeatherAreaObject). The weather area object is used to set precipitation, fog, lightning, and other environmental conditions.
Note that currently there many stub methods in here for future capabilities.
Classes | |
| struct | CloudLayerData |
| struct | CloudLayerSortComparator |
Public Member Functions | |
| DtLocalEnvironmentalsControllerObject (DtDe &de, DtUniqueID id) | |
| virtual | ~DtLocalEnvironmentalsControllerObject () |
| DtLocalEnvironmentalsControllerObject ()=delete | |
| DtLocalEnvironmentalsControllerObject (const DtLocalEnvironmentalsControllerObject &)=delete | |
| DtLocalEnvironmentalsControllerObject & | operator= (const DtLocalEnvironmentalsControllerObject &)=delete |
| virtual DtCloudLayerId | addLayerToCloudCover (const DtCloudLayer &layer, const std::string &coverName) |
| virtual void | setZoneOrigin (double x, double y, double z) |
| virtual void | setZoneShape (double width, double length, double height, double cornerRadius) |
| virtual void | setAirTurbidity (float turbidity) |
| virtual void | setAmbientAirTemperature (float temperature) |
| virtual void | setAmbientAirPressure (float pressure) |
| virtual void | setAirTemperatureAltitude (float altitude) |
| virtual void | setAirPressureAltitude (float altitude) |
| virtual void | setAirTemperatureAltitudeIsSeaLevel (bool seaLevel) |
| virtual void | setAirPressureAltitudeIsSeaLevel (bool seaLevel) |
| virtual void | setSeaLevelWaterConcentration (float water) |
| virtual void | setLightningPresent (bool lightningPresent) |
| virtual void | setBlowingParticulateMatter (unsigned int type) |
| virtual void | setPrecipitationType (unsigned int type) |
| virtual void | setPrecipitationIntensity (float intensity) |
| virtual void | setTimeOfDay (int hour, int minutes, double seconds) |
| virtual void | setDateAndTimeOfDay (int year, int month, int day, int hour, int minutes, double seconds) |
| virtual void | setUseGlobalTimeZone (bool value) |
| virtual void | setTimeOfDayAdvancementSpeed (float speed) |
| virtual void | setFogHeight (float value) |
| virtual void | setFogColor (const DtVector &color) |
| virtual void | setFogColor (float red, float green, float blue) |
| virtual void | setFogColor (int red, int green, int blue) |
| virtual void | removeElevationalConfiguration (float baseMSLAltitude) |
| virtual void | updateOrAddElevationalConfiguration (float baseMSLAltitude, float windSpeed, float windDirection, float visibilityDistance, unsigned int obscurant, int cloudType, float cloudDensity, float skyCoverage) |
| virtual void | setSwellState (int state) |
| virtual void | setSwellStateDirection (float value) |
| virtual void | setSeaState (int state) |
| virtual void | setSeaStateDirection (float value) |
| virtual void | setWindDrivenSeaStateEnabled (bool value) |
| virtual void | setWindFetch (float value) |
| virtual void | setSeaChoppiness (float value) |
| virtual void | setUnderwaterVisibility (float distance) |
| virtual void | setSurfaceTransparency (float value) |
| virtual void | setSurgeDepth (float value) |
| virtual void | setAmbientWaterTemperature (float temperature) |
| virtual void | setWaterCurrentSpeed (float speed) |
| virtual void | setWaterCurrentDirection (float direction) |
| virtual void | setTidalOffset (float meters) |
| virtual void | setTidalDirection (bool inOut) |
| virtual void | setThermoclineDepth (unsigned int layer, float value) |
| virtual void | setThermoclinePermeability (unsigned int layer, float value) |
| virtual void | setGroundSnowAccumulation (float depth) |
| virtual void | setRoadSnowAccumulation (float depth) |
| virtual void | setSnowMinimumElevation (float elevation) |
| virtual void | setSnowElevationTransition (float elevation) |
| virtual void | setGroundRainAccumulation (float depth) |
Protected Types | |
| typedef std::vector < CloudLayerData * > | CloudLayerSet |
Protected Member Functions | |
| virtual bool | ensureWeatherAreaCreated () |
| virtual void | computeOriginBasis (DtVector &origin, DtVector &north, DtVector &east, DtVector &up) |
| virtual int | mapBlowingParticulateMatterToCloudType (unsigned int type) const |
| virtual void | updateOrAddCloudForElevation (float baseMSLAltitude, int cloudType, float cloudDensity, float skyCoverage, float visibilityDistance) |
| virtual bool | hasCloud (float baseMSLAltitude, int cloudType, float cloudDensity, float skyCoverage, float visibilityDistance) const |
| virtual void | removeAllCloudsAtElevation (float baseMSLAltitude) |
| virtual void | refreshCloudLayerThicknessIfNeeded () |
| virtual void | adjustWeatherAreaForClouds () |
| virtual const float | computeDensityFromVisibility (const float visibility) const |
| virtual const float | computeCloudThickness (const float baseMSLAltitude) const |
| virtual void | slot_coordinateSystemChanged () |
Protected Attributes | |
| DtDe & | myDe |
| DtVector | myOrigin |
| double | myWidth |
| double | myLength |
| double | myHeight |
| double | myCornerRadius |
| CloudLayerSet | myCloudLayerSet |
| unsigned int | myPrecipitationType |
| float | myPrecipitationIntensity |
| float | myGroundRainAccumulation |
| DtVector | myFogColor |
| float | myVisibilityDistance |
| float | myOvercast |
| float | myWindDirection |
| float | myWindSpeed |
| bool | myLightningEnabled |
| unsigned int | myBlowingParticulateMatter |
| DtUniqueID | myWeatherAreaId |
| DtSignalConnectionManager | myConnections |
| DtCoordinateConverter * | myCoordinateConverter = nullptr |
|
protected |
This type defines a set of cloud layers.
| makVrv::DtLocalEnvironmentalsControllerObject::DtLocalEnvironmentalsControllerObject | ( | DtDe & | de, |
| DtUniqueID | id | ||
| ) |
CTOR.
|
virtual |
DTOR.
|
delete |
Default Constructor not implemented – default constructor not allowed.
|
delete |
Copy Constructor not implemented – Copy not allowed.
|
delete |
Assignment Operator not implemented – Copy not allowed.
|
virtual |
Add the cloud layer to the specified cloud cover (in the DtCloudCoverManager).
| layer | The layer (settings) to add. |
| coverName | The name of the cloud coverage to add to. |
|
virtual |
Set the origin of the zone in the database coordinate system.
| x | The origin x component. |
| y | The origin y component. |
| z | The origin z component. |
|
virtual |
Sets the shape of the zone. The bounds is a rounded rect with height. Note that currently height is not acutally used but it is here for future expansion with the concept of layers. Currently height is auto-computed based on the lowest precipitation cloud bottom and the zone origin.
| width | The bounds width. |
| length | The bounds length. |
| height | The bounds height. |
| cornerRadius | The bounds cornerRadius. |
|
virtual |
Set the air turbidity/haziness.
| turbidity | The desired turbidity. |
|
virtual |
Set the ambient air temperature, in Kelvins.
| temperature | The desired temperature. |
|
virtual |
Set the ambient air pressure, in Pascals.
|
virtual |
Set the air temperature altitude, in meters.
|
virtual |
Set the air pressure altitude, in meters.
|
virtual |
Set the air temperature altitude is sea level flag.
|
virtual |
Set the air pressure altitude is sea level flag.
|
virtual |
Set the sea level water concentration, in PPMV (parts per million by volume).
|
virtual |
Sets whether or not lightning is present.
|
virtual |
Set the blowing particulate matter type.
| type | The DtEnvironment::BlowingParticulateMatterType enumeration value. |
|
virtual |
Sets precipitation type.
| type | The DtEnvironmentInterface::PrecipitationType enumeration value. |
|
virtual |
Sets precipitation intensity.
| The | desired precipitation intensity. |
|
virtual |
Tell the scene to change the time of day.
| hour | The time of day hour. |
| minutes | The time of day minutes. |
| seconds | The time of day seconds. |
|
virtual |
Tell the scene to change the date and time of day.
| year | The date year. |
| month | The date month. |
| day | The date day. |
| hour | The time of day hour. |
| minutes | The time of day minutes. |
| seconds | The time of day seconds. |
|
virtual |
Tell the system to use GMT time as the means to position the sun/moon rather than always moving with the observer. This will set the value in the environment settings manager.
| value | Set to true to use global time zone. |
|
virtual |
Tell the scene to change the time of day advancement speed.
| speed | The advancement speed. |
|
virtual |
Sets the fog ceiling height.
| value | The fog height in meters. |
|
virtual |
Sets the fog color.
| color | The (r,g,b) color values in the range (0.0 - 1.0) |
|
virtual |
Sets the fog color.
| red | The red color value in the range (0.0 - 1.0) |
| green | The green color value in the range (0.0 - 1.0) |
| blue | The blue color value in the range (0.0 - 1.0) |
|
virtual |
Sets the fog color.
| red | The red color value in the range (0 - 255) |
| green | The green color value in the range (0 - 255) |
| blue | The blue color value in the range (0 - 255) |
|
virtual |
Removes an elevational configuration record by its base MSL altitude, in meters.
|
virtual |
Update an elevational configuration record which consists of 1) a base MSL altitude, in meters, 2) a wind speed, in meters per second, 3) a wind direction, in radians from True North (clockwise), 4) a visibility distance, in meters, 5) an enumerated visibility obscurant value, 6) the type of cloud present, by name, and 7) the sky coverage of the cloud, in normalized Oktas [0-1]. If the elevational configuration record doesn't exist, add a new one with the passed in attributes.
|
virtual |
Set the sea swell conditions based on the Douglas sea scale.
| state | The swell state. |
|
virtual |
Set the direction, in radians from True North, of sea swells.
| value | The direction. |
|
virtual |
Set the sea state conditions based on the Douglas sea scale.
| state | The sea state. |
|
virtual |
Set the sea state direction in radians from True North.
| value | The direction. |
|
virtual |
Set the wind driven seas enabled parameter to allow the wind to determine the sea state.
| value | Set to true to enable wind driven sea state. |
|
virtual |
Set the ocean wind fetch.
| value | The desired fetch. |
|
virtual |
Set the sea choppiness.
| value | The desired choppiness. |
|
virtual |
Set the maximum visibility under water in meters.
| distance | The visibility distance. |
|
virtual |
Set the surface transparency.
| value | The surface transparency. |
|
virtual |
Set the surge depth.
| value | The surge depth. |
|
virtual |
Set the ambient water temperature, in Kelvins.
| temperature | The ambient water temperature. |
|
virtual |
Set the speed of water currents in meters per second.
| speed | The desired speed. |
|
virtual |
Set the direction of water currents in radians from north (clockwise).
| direction | The desired direction. |
|
virtual |
Set the current tidal offset from mean-sea-level in meters.
| meters | The offset. |
|
virtual |
Set the current direction of tidal flow (0=out, 1=in).
| inOut | Set to false for "out", and true for "in". |
|
virtual |
Set a thermocline depth.
| layer | The desired layer to affect. |
| value | The depth. |
|
virtual |
Set a thermocline permeability.
| layer | The desired layer to affect. |
| value | The permeability. |
|
virtual |
Set the ground snow accumulation percentage.
| depth | The accumulation depth. |
|
virtual |
Set the road snow accumulation percentage.
| depth | The accumulation depth. |
|
virtual |
Set the snow minimum elevation.
| elevation | The elevation at which accumulation starts to become visible. |
|
virtual |
Set the snow elevation transition which specifies how long it takes to go from no snow to the full snow depth.
| elevation | The elevation at which accumulation is fully visible. |
|
virtual |
Set the ground rain accumulation percentage.
| depth | The accumulation depth. |
|
protectedvirtual |
Creates the weather area if it does not exist. If newly created, all current weather parameters are set for the area. Returns true if already exists otherwise it returns false.
|
protectedvirtual |
Computes the local origin and basis vectors from the current myOrigin.
| origin | The computed output origin. |
| north | The computed output north vector. |
| east | The computed output east vector. |
| up | The computed output up vector. |
|
protectedvirtual |
Maps a blowing particulate matter type (makArchives::BlowingParticulateMatterType) to a cloud type (DtCloudTypeMapper::CloudType) used specifically for blowing particulate matter such as dust, sand, and snow.
|
protectedvirtual |
Updates a the cloud associated with the elevational. If no cloud is associated with the given elevational, a new one is added, otherwise the cloud parameters are updated with the new attributes.
| baseMSLAltitude | A base MSL altitude, in meters. |
| cloudType | The type of cloud (see DtCloudTypeMapper::CloudType). |
| cloudDensity | The cloud density. |
| skyCoverage | The sky coverage of the cloud, in normalized Oktas [0-1]. |
| visibilityDistance | The visibility distance for the layer. |
|
protectedvirtual |
Checks if there is a cloud that matches the given parameters.
|
protectedvirtual |
removes any clouds at the given elevation.
|
protectedvirtual |
Refresh the thickness of all the cloud layers for the current environment configuration, if needed, based on the base MSL altitudes of all the elevational configurations being maintained.
|
protectedvirtual |
Updates the weather area bounds and lighting based on the current set of clouds.
|
protectedvirtual |
Computes a exp2 falloff density based on visibility.
| The | visibility to use for the caclulation. |
|
protectedvirtual |
Computes a cloud thickness for the given base altitude based on current elevation configuration data.
| baseMSLAltitude | The altitude to compute from. |
|
protectedvirtual |
slot for when the coordinate system changes
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
local clone of the current system wide coordinate system converter. for thread safety.