Triton
Visual simulation library for ocean rendering.
Public Member Functions | List of all members
Triton::BreakingWavesParameters Class Reference

Parameters to control behavior of breaking waves at shorelines, used by Environment::SetBreakingWaves(). More...

#include <Environment.h>

Inheritance diagram for Triton::BreakingWavesParameters:
Inheritance graph
[legend]
Collaboration diagram for Triton::BreakingWavesParameters:
Collaboration graph
[legend]

Public Member Functions

 BreakingWavesParameters ()
 The constructor sets reasonable default values, except for the waveDirection member which we can't really guess at.
 
void SetSteepness (float pSteepness)
 The "k" value controlling the steepness of the waves; 0 is rounded sine wave, 1.0 is pointy.
 
void SetWavelength (float pWavelength)
 The starting wavelength of the breaking waves.
 
void SetWavelengthVariance (float pWavelengthVariance)
 How much the wavelength varies as the wave approaches the shore.
 
void SetWaveDirection (const Vector3 &pDirection)
 The normalized direction vector pointing toward the shoreline.
 
void SetAutoWaveDirection (bool on)
 Sets whether the direction of the waves should be automatically determined by examining the overall slope of the terrain described by the current height map.
 
void SetAmplitude (float pAmplitude)
 The amplitude of the breaking waves.
 
void SetSurgeDepth (float pSurgeDepth)
 The depth at which the wavelength will rapidly expand to simulate surging surf.
 
void SetSteepnessVariance (float pSteepnessVariance)
 The variance in steepness as the wave approaches the shore.
 
void SetDepthFalloff (float pFalloff)
 How quickly breaking waves fade off as a function of water depth.
 

Detailed Description

Parameters to control behavior of breaking waves at shorelines, used by Environment::SetBreakingWaves().

Member Function Documentation

◆ SetAmplitude()

void Triton::BreakingWavesParameters::SetAmplitude ( float  pAmplitude)
inline

The amplitude of the breaking waves.

Default: 3.0

◆ SetAutoWaveDirection()

void Triton::BreakingWavesParameters::SetAutoWaveDirection ( bool  on)
inline

Sets whether the direction of the waves should be automatically determined by examining the overall slope of the terrain described by the current height map.

If false, the explicit wave direction set via SetWaveDirection() will be used instead. Defaults to off.

◆ SetDepthFalloff()

void Triton::BreakingWavesParameters::SetDepthFalloff ( float  pFalloff)
inline

How quickly breaking waves fade off as a function of water depth.

1.0 will give you "physically realistic" results, but often not what you expect. Larger values will cause breaking waves to fade away closer to shore. Default: 5.0

◆ SetSteepness()

void Triton::BreakingWavesParameters::SetSteepness ( float  pSteepness)
inline

The "k" value controlling the steepness of the waves; 0 is rounded sine wave, 1.0 is pointy.

This will automatically increase as the wave approaches the shore; you're just specifying the starting value here. Default: 0.5

◆ SetSteepnessVariance()

void Triton::BreakingWavesParameters::SetSteepnessVariance ( float  pSteepnessVariance)
inline

The variance in steepness as the wave approaches the shore.

Default: 0.5

◆ SetSurgeDepth()

void Triton::BreakingWavesParameters::SetSurgeDepth ( float  pSurgeDepth)
inline

The depth at which the wavelength will rapidly expand to simulate surging surf.

Default: 8.0

◆ SetWaveDirection()

void Triton::BreakingWavesParameters::SetWaveDirection ( const Vector3 pDirection)
inline

The normalized direction vector pointing toward the shoreline.

Used only if SetAutoWaveDirection(false) has been called, or if automatic detection of the ocean floor's slope fails for some reason.

◆ SetWavelength()

void Triton::BreakingWavesParameters::SetWavelength ( float  pWavelength)
inline

The starting wavelength of the breaking waves.

Default: 1500.0

◆ SetWavelengthVariance()

void Triton::BreakingWavesParameters::SetWavelengthVariance ( float  pWavelengthVariance)
inline

How much the wavelength varies as the wave approaches the shore.

Default: 500.0


The documentation for this class was generated from the following file: