Default vrvOsg implementation of DtLocalWeatherQuery.
Delegates to DtWeatherAreaGroup::computeLocalPrecipitation() and computeLocalWind(), which are the same functions used by the visual renderer. This guarantees that audio onset boundaries match the visual rain and wind boundaries exactly, including the 0.95 bounds scale applied inside DtWeatherArea::computeLocalPrecipitation().
An instance is registered per-De automatically during DtOsgSkyObject construction via registerInstance(). Toolkit users can replace it by calling DtLocalWeatherQuery::registerInstance() with a subclass after DtOsgSkyObject has been constructed.
| makVrv::DtOsgLocalWeatherQuery::DtOsgLocalWeatherQuery |
( |
DtDe & |
de | ) |
|
|
explicit |
| virtual makVrv::DtOsgLocalWeatherQuery::~DtOsgLocalWeatherQuery |
( |
| ) |
|
|
virtual |
| virtual bool makVrv::DtOsgLocalWeatherQuery::getLocalPrecipitation |
( |
const DtVector & |
observerPos, |
|
|
bool & |
raining, |
|
|
float & |
normalizedIntensity |
|
) |
| const |
|
overridevirtual |
Query local precipitation at observerPos via DtWeatherAreaGroup.
Returns true if any active local rain area covers the position. The normalizedIntensity value is blended using the same 30 m edge-fade and 0.95 bounds scale as the visual rain boundary.
Implements makVrv::DtLocalWeatherQuery.
| virtual bool makVrv::DtOsgLocalWeatherQuery::getLocalWind |
( |
const DtVector & |
observerPos, |
|
|
bool & |
audible, |
|
|
float & |
speedMs, |
|
|
float & |
directionRad |
|
) |
| const |
|
overridevirtual |
| virtual bool makVrv::DtOsgLocalWeatherQuery::getLocalVisibility |
( |
const DtVector & |
observerPos, |
|
|
float & |
visibilityMeters |
|
) |
| const |
|
overridevirtual |
Query local visibility at observerPos via DtWeatherAreaGroup.
Returns true if any active local weather area covers the position. visibilityMeters is the lowest (densest fog) value among all covering areas, matching the same edge-fade boundary used by the visual renderer.
Implements makVrv::DtLocalWeatherQuery.
| static void makVrv::DtOsgLocalWeatherQuery::registerInstance |
( |
DtDe & |
de | ) |
|
|
static |
Register a DtOsgLocalWeatherQuery for the given De.
Called automatically from DtOsgSkyObject's constructor. Only registers once; subsequent calls on the same De are a no-op so that user-supplied subclasses installed before sky-object creation are not overwritten.
| DtDe& makVrv::DtOsgLocalWeatherQuery::myDe |
|
protected |
De this adapter is bound to.
The documentation for this class was generated from the following file: