![]() |
VR-Forces 5.0.3 Developer's Guide
|

Public Types | |
| enum | TritonQuality { TritonQuality_Good, TritonQuality_Better, TritonQuality_Best } |
| enum | TritonSpectralModel { TritonSpectralModel_JonSwap = 0, TritonSpectralModel_Pierson_Moskowitz, TritonSpectralModel_Tessendorf } |
Public Member Functions | |
| virtual | ~DtTritonManager () |
| virtual void | addToScene () |
| virtual void | oceanLayerAdded () |
| virtual void | oceanLayerToBeDeleted () |
| virtual void | setSeaLevel (float level) |
| virtual float | seaLevel () const |
| virtual void | setElevationLod (double maxElevation) |
| virtual double | elevationLod () const |
| virtual void | setWind (double speed, double direction, double fetch=0.0) |
| virtual void | setDouglasSeaState (DtDouglasSeaState::Scale seaState, double seaStateDirection, DtDouglasSwellState::Scale swellState, double swellStateDirection) |
| virtual void | addSwell (float wavelength, float waveHeight, float radiansClockwiseFromNorth) |
| virtual void | clearSwells () |
| virtual void | setChoppiness (float chop) |
| virtual bool | getIsUnderwater (const osg::Camera *osgCamera) const |
| virtual void | setUnderwaterVisibility (double distance) |
| virtual bool | setUnderwaterFogColor (const DtVector &fogColor) |
| virtual void | setUnderwaterFogEnabled (bool enabled) |
| virtual void | setWaterColor (const DtVector &waterColor) |
| virtual DtVector | waterColor () const |
| virtual double | waterVisibility () const |
| virtual void | setWaterVisibility (double distance) |
| virtual void | setSurfaceTransparency (double transparency) |
| virtual bool | setSurgeDepth (float depth) |
| virtual bool | getSurgeDepth (float &depth) const |
| virtual void | setDepthOffset (float offset) |
| virtual bool | intersect (const DtVector &position, DtVector &positionOut, DtVector &normalOut, float waterlineAdjustment=0.0) |
| virtual bool | intersectSeaLevel (const DtVector &position, const DtVector &direction, DtVector &positionOut) |
| virtual bool | getHeight (const DtVector &position, const DtVector &direction, double &height, DtVector &normalOut) |
| virtual Triton::WakeGenerator * | createWake (const Triton::WakeGeneratorParameters ¶meters) |
| virtual Triton::RotorWash * | createRotorWash (double rotorDiameter) |
| virtual Triton::Impact * | createImpact (double impactorDiameter, double mass, double sprayScale) |
| virtual Triton::TidalStreamWake * | createTidalStreamWake (double size, double draft, double maxWaveHeight, double offset) |
| virtual void | setWaveSprayEffects (bool waveSprayEnabled) |
| virtual bool | waveSprayEffects () const |
| virtual void | setDecalEffects (bool decalsEnabled) |
| virtual bool | decalEffects () const |
| virtual void | setGodRayEffects (bool godRaysEnabled) |
| virtual bool | godRayEffects () const |
| virtual void | setBreakingWaveAmplitude (float meters) |
| virtual float | getBreakingWaveAmplitude () const |
| virtual float | getMaximumWaveHeight () |
| virtual void | setHeightMapResolution (float metersPerTexel) |
| virtual bool | getHeightMapResolution (float &metersPerTexel) const |
| virtual void | setSeaState (DtBeaufortWindScale::Scale beaufortScale) |
| virtual DtBeaufortWindScale::Scale | seaState () const |
| virtual void | setBeach (const DtVector &origin, const DtVector &normal) |
| virtual void | setPlanarReflections (bool enable) |
| virtual bool | planarReflections () const |
| virtual void | setHeightMap (bool enable) |
| virtual bool | heightMap () const |
| virtual void | setCorrelateIntersectionsToVisuals (bool visualCorrelation) |
| virtual bool | correlateIntersectionsToVisuals () const |
| virtual void | setOceanMaskTextureEnabled (bool enable) |
| virtual bool | isOceanMaskTextureEnabled () const |
| virtual bool | isOverWater (const DtVector &localPosition, bool isVisible=true) |
| virtual bool | addedToScene () |
| virtual void | setIsVisible (bool visible, unsigned int frameNum) |
| virtual bool | getIsVisible () |
| virtual DtTime | oceanTime () const |
| virtual DtTritonDrawable * | tritonDrawable () const |
| virtual double | getOceanZoomOverride () const |
| virtual void | setOceanZoomOverride (double zoomOverride) |
| virtual void | setFreezeEnabled (bool enable) |
| virtual bool | freezeEnabled () const |
| virtual void | setFreezeTime (DtTime freezeAtTime) |
| virtual DtTime | freezeTime (void) const |
| virtual void | setIncludeWakesInIntersections (bool includeWakes) |
| virtual bool | includeWakesInIntersections () const |
| virtual void | setQuality (unsigned int quality) |
| virtual TritonQuality | quality () const |
| virtual void | setSpectralModel (unsigned int spectralModel) |
| virtual TritonSpectralModel | spectralModel () const |
Public Member Functions inherited from makVrv::DtVirtualBaseClass | |
| DtVirtualBaseClass () | |
| virtual | ~DtVirtualBaseClass () |
Static Public Member Functions | |
| static DtTritonManager & | instance (makVrv::DtDe &de) |
Public Attributes | |
| boost::signalslib::signal< void()> | signal_oceanInitialized |
| boost::signalslib::signal< void()> | signal_addedToScene |
| boost::signalslib::signal< void()> | signal_removedFromScene |
| boost::signalslib::signal< void()> | signal_oceanToBeDestroyed |
| boost::signalslib::signal < void(DtPlanarReflection *reflection)> | signal_planarReflectionCreated |
| boost::signalslib::signal < void(double)> | signal_shipSpeedChanged |
Protected Member Functions | |
| DtTritonManager (makVrv::DtDe &de) | |
| void | slot_postInitialize () |
| void | slot_driverToBeDestroyed (DtDriver &driver) |
| virtual void | installEventProcessor () |
| void | slot_postUpdate () |
| virtual DtDynamicOceanObject * | dynamicOcean () const |
Static Protected Attributes | |
| static const float | theMaxWindSpeedForWindFetch |
|
virtual |
destructor
|
protected |
cannot create directly
|
static |
access the instance
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Set the wind effects on ocean waves.
| [in] | speed | is in meters per second. |
| [in] | direction | is in radians clockwise from north. |
| [in] | fetch | is fetch distance in meters. |
|
virtual |
Set the Douglas sea and swell states.
| [in] | seaState | is the sea-state generated by local winds (0 - 9). |
| [in] | seaStateDirection | is the direction of the sea-state. |
| [in] | swellState | is the swell-state generated afar (0 - 9). |
| [in] | swellStateDirection | is the direction of the swells. |
|
virtual |
|
virtual |
|
virtual |
Set the choppiness of the waves.
| [in] | chop | is a normalized value from 0.0 to 1.0. |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Get the intersection with a wave, assuming the position is directly above the sea (vertical)
|
virtual |
Get an intersection of a ray starting at position and pointing in direction with the sea level plane This can potentially query the externally provided height map that triton stores internally. If so, this must be called where the OpenGL context is current.
|
virtual |
Get the height of the wave field intersected by a ray starting at position pointing in direction This can potentially query the externally provided height map that triton stores internally. If so, this must be called where the OpenGL context is current.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Create a wake from a fixed object such as a buoy or bridge pile, with a given wave length, draft (distance below water the object extends,) and maximum wave amplitude. Call Update() on this object each frame to activate it for a given position, direction, and tidal stream velocity.
|
virtual |
Toggle spray effects from high wave crests.
|
virtual |
|
virtual |
Toggle use of decal textures on rotor wash for subsquently created rotor washes.
|
virtual |
|
virtual |
Toggles underwater "god rays" or shafts of light.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Returns maximum wave height just based on the sea state.
|
virtual |
Get/set the meters represented by one height map texel.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
whether to include wakes in intersection queries By default, true. Setting it to false can improve performance
|
virtual |
whether to include wakes in intersection queries By default, true. Setting it to false can improve performance
|
virtual |
Get/set a flag for disabling the ocean mask texture. This is used by the SOE since it doesn't need a mask and it is crashing on Centos8.
|
virtual |
Set quality of wave simulation - "good" yields best performance but least detail, "best" favors quality over performance. Default is good.
|
virtual |
Set quality of wave simulation - "good" yields best performance but least detail, "best" favors quality over performance. Default is good.
set the spectral model (Jonswap, Pierson-Moskowitz. Tessendorf)
|
virtual |
set the spectral model (Jonswap, Pierson-Moskowitz. Tessendorf)
|
virtual |
Returns whether we are currently over water. This can't be implemented correctly until we have coastal boundaries. For now, we use a call to Triton::Ocean->GetIntersection() if isVisible is true; this only works if there is a valid height map in the area of the query, which means it will only work correctly if there is a camera (observer) in the query area; it really should only be used for things that are LOD'd out when not close to an observer; things like wakes on amphibious vehicles, tidal stream wakes, or rotor wash. We use the returned height of a terrain intersect call if isVisible is false; sea level or below is water, anything higher is not.
|
virtual |
Called by traversal. If any call for the given frame number is true, then.
|
virtual |
Is the ocean currently rendered in at least one viewport?
|
virtual |
Get the time (in seconds) that triton is using for its simulation This may be simulation time or wall clock time.
|
virtual |
|
virtual |
zoom override
|
virtual |
|
virtual |
Set the freeze enable flag which stops time for triton.
|
virtual |
get the freeze enable flag which stops time for triton Currently only used by the auto test plugin
|
virtual |
as above. freeze at a given time, if frozen.
|
virtual |
as above. return the time at which frozen, if set to frozen.
|
protected |
|
protected |
|
protectedvirtual |
|
protected |
Slot that is called once per tick in the post update phase. This is used to update camera culling parameters above water state.
|
protectedvirtual |
Helper function to get the dynamic ocean.
| boost::signalslib::signal<void()> makVrv::DtTritonManager::signal_oceanInitialized |
| boost::signalslib::signal<void()> makVrv::DtTritonManager::signal_addedToScene |
| boost::signalslib::signal<void()> makVrv::DtTritonManager::signal_removedFromScene |
| boost::signalslib::signal<void()> makVrv::DtTritonManager::signal_oceanToBeDestroyed |
| boost::signalslib::signal<void (DtPlanarReflection* reflection)> makVrv::DtTritonManager::signal_planarReflectionCreated |
Signal emitted when a new planar reflection has been created.
| boost::signalslib::signal<void(double)> makVrv::DtTritonManager::signal_shipSpeedChanged |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
whether frozen. used by the auto tests
|
protected |
|
staticprotected |