FhSim  3.1.0
Marine systems simulation
Loading...
Searching...
No Matches
visual::sky::SkyModel Class Reference

#include <SkyModel.h>

Public Member Functions

 SkyModel (const Atmosphere &atmosphere, const Vec3 &sunDirection, double cameraAltitude=10.0)
 
Rgb Radiance (const Vec3 &direction, int steps=32) const
 
Rgb SunIrradiance (double altitude) const
 
Rgb SunIrradiance () const
 Direct sun irradiance at the eye (see SunIrradiance(double)).
 
Rgb SunDiscRadiance () const
 Mean radiance of the sun's disc at the eye [1/sr]: SunIrradiance() / (pi radius^2).
 
Rgb SkyIrradiance (int samples=24) const
 
Rgb Transmittance (double r, double mu) const
 
const Atmosphere & Air () const
 
const Vec3 & SunDirection () const
 
double Altitude () const
 
Rgb MeanExtinctionBelow (double h) const
 

Detailed Description

The clear sky seen from one point above the sea, for one sun direction.

The constructor fills the transmittance and multiple-scattering tables (a few ms).

Constructor & Destructor Documentation

◆ SkyModel()

visual::sky::SkyModel::SkyModel ( const Atmosphere &  atmosphere,
const Vec3 &  sunDirection,
double  cameraAltitude = 10.0 
)
Parameters
[in]atmosphereThe atmosphere.
[in]sunDirectionTowards the sun, NED, unit (may be below the horizon).
[in]cameraAltitudeHeight of the eye above the sea [m], clamped to at least 1 m.

Member Function Documentation

◆ Air()

const Atmosphere & visual::sky::SkyModel::Air ( ) const
inline
Returns
The atmosphere.

◆ Altitude()

double visual::sky::SkyModel::Altitude ( ) const
inline
Returns
The eye altitude [m].

◆ MeanExtinctionBelow()

Rgb visual::sky::SkyModel::MeanExtinctionBelow ( double  h) const
Returns
Mean extinction [1/m] of the air between the sea and the altitude h (for haze in front of clouds).

◆ Radiance()

Rgb visual::sky::SkyModel::Radiance ( const Vec3 &  direction,
int  steps = 32 
) const

Sky radiance seen in a direction, without the sun's disc, per unit solar irradiance [1/sr].

Below the horizon the ray ends at the sea: the result is only the air light in front of it.

Parameters
[in]directionView direction, NED, unit.
[in]stepsNumber of march steps.

◆ SkyIrradiance()

Rgb visual::sky::SkyModel::SkyIrradiance ( int  samples = 24) const

Irradiance of the clear sky (not the sun) on a horizontal surface at the eye, per unit solar irradiance.

Parameters
[in]samplesDirections per axis of the hemisphere quadrature.

◆ SunDirection()

const Vec3 & visual::sky::SkyModel::SunDirection ( ) const
inline
Returns
The sun direction, NED, unit.

◆ SunIrradiance()

Rgb visual::sky::SkyModel::SunIrradiance ( double  altitude) const

Direct sun irradiance at an altitude, on a plane normal to the beam, per unit solar irradiance. Zero when the sun is below the horizon there.

◆ Transmittance()

Rgb visual::sky::SkyModel::Transmittance ( double  r,
double  mu 
) const

Transmittance from radius r along a ray of zenith cosine mu to the top of the atmosphere (ignores the ground).

Parameters
[in]rDistance from the centre of the Earth [m].
[in]muCosine of the ray's zenith angle.

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