Empeld
Empeld plugin documentation.
essentials.Environment.Fog.AtmosphereVolumeFog Class Reference

Fog that computes a low-level volumetric fog More...

Inheritance diagram for essentials.Environment.Fog.AtmosphereVolumeFog:
essentials.Environment.Fog.AtmosphereFog pluginbase.Objects.World.Environment.IVolumeFog pluginbase.Objects.World.Environment.Fog.FogBase pluginbase.Objects.World.Environment.IFog pluginbase.Objects.World.Environment.IFog pluginbase.Objects.World.Environment.IEnvironmentSimulatable pluginbase.Objects.World.Environment.IEnvironmentSimulatable

Public Member Functions

 AtmosphereVolumeFog (IEnumerable< IOrbital > orbitals, double highZ=0.0, double lowZ=-10_000.0)
 
override void Simulate (double time, double x, double y, double z)
 Simulate the environment with the time, and an x/y/z More...
 
- Public Member Functions inherited from essentials.Environment.Fog.AtmosphereFog
 AtmosphereFog (IEnumerable< IOrbital > orbitals)
 

Protected Attributes

virtual float VolumeDensity => 0.05f
 

Additional Inherited Members

- Properties inherited from essentials.Environment.Fog.AtmosphereFog
virtual Rgba FogColorBase [get]
 
sealed override Rgba Color [get]
 
- Properties inherited from pluginbase.Objects.World.Environment.Fog.FogBase
virtual FogType RenderMode [get]
 
virtual float Density [get]
 
virtual Rgba Color [get]
 
- Properties inherited from pluginbase.Objects.World.Environment.IFog
FogType RenderMode [get]
 Gets the fog render mode More...
 
float Density [get]
 Gets the fog density More...
 
Rgba Color [get]
 Gets the color of the fog More...
 
- Properties inherited from pluginbase.Objects.World.Environment.IVolumeFog
float VolumeDensity [get]
 Density of the volumetric fog More...
 
double LowZ [get]
 How low the fog goes More...
 
double HighZ [get]
 How high the fog goes More...
 

Detailed Description

Fog that computes a low-level volumetric fog

Constructor & Destructor Documentation

◆ AtmosphereVolumeFog()

essentials.Environment.Fog.AtmosphereVolumeFog.AtmosphereVolumeFog ( IEnumerable< IOrbital orbitals,
double  highZ = 0.0,
double  lowZ = -10_000.0 
)
17  : base(orbitals)
18  {
19  _orbitals = orbitals.Where(x => x.HasEmittance).ToArray();
20  _highZ = highZ;
21  _lowZ = lowZ;
22  }

Member Function Documentation

◆ Simulate()

override void essentials.Environment.Fog.AtmosphereVolumeFog.Simulate ( double  time,
double  x,
double  y,
double  z 
)
virtual

Simulate the environment with the time, and an x/y/z

Parameters
timeTime.
xX.
yY.
zZ.

Reimplemented from essentials.Environment.Fog.AtmosphereFog.

34  {
35  base.Simulate(time, x, y, z);
36  _volumePower = 1f - Math.Min(1f, _orbitals.Sum(o => o.EmittanceDiffuse.Luminosity * Math.Max(0f, o.Direction.Z * 1.5f)));
37  }

Member Data Documentation

◆ VolumeDensity

virtual float essentials.Environment.Fog.AtmosphereVolumeFog.VolumeDensity => 0.05f
protected

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