Agrarsense
Public Member Functions | Public Attributes | List of all members
FWeatherParameters Struct Reference

#include <WeatherParameters.h>

Public Member Functions

bool IsWinterSnowCondition ()
 
bool IsLidarNoiseModelCondition ()
 
FString ToString () const
 
FString ToStringHumanReadable () const
 

Public Attributes

float Temperature = 10.0f
 
float Precipitation = 0.0f
 
float PrecipitationParticleSize = 1.0f
 
float Cloudiness = 0.05f
 
float Fog = 0.0f
 
float FogFalloff = 0.2f
 
float WindIntensity = 0.0f
 
float WindDirection = 15.0f
 
float SnowAmount = 0.0f
 
float TreeSnowiness = 0.0f
 
int Month = 7
 
int Time = 12
 

Detailed Description

Definition at line 11 of file WeatherParameters.h.

Member Function Documentation

◆ IsLidarNoiseModelCondition()

bool FWeatherParameters::IsLidarNoiseModelCondition ( )
inline

Checks if the current weather conditions allow for a Lidar noise model to be used.

Returns
true if the Lidar noise model can be applied in the current weather.

Definition at line 60 of file WeatherParameters.h.

61 {
62 return Temperature <= 0.0f && Precipitation != 0.0f;
63 }

Referenced by ALidar::SimulateRaycastLidar().

◆ IsWinterSnowCondition()

bool FWeatherParameters::IsWinterSnowCondition ( )
inline

Definition at line 51 of file WeatherParameters.h.

52 {
53 return SnowAmount != 0.0f;
54 }

Referenced by ALidar::AddSnowTerrainAdjustment().

◆ ToString()

FString FWeatherParameters::ToString ( ) const
inline

Definition at line 65 of file WeatherParameters.h.

66 {
67 return FString::Printf(
68 TEXT("%f, %f, %f, %f, %f, %f, %f, %f, %f, %f, %d, %d"),
73 Fog,
79 Month,
80 Time
81 );
82 }

◆ ToStringHumanReadable()

FString FWeatherParameters::ToStringHumanReadable ( ) const
inline

Definition at line 84 of file WeatherParameters.h.

85 {
86 return FString::Printf(
87 TEXT("Temperature: %.2f, Precipitation: %.2f, Precipitation Particle Size: %.2f, Cloudiness: %.2f, Fog: %.2f, Fog Falloff: %.2f, Wind Intensity: %.2f, Wind Direction: %.2f, Snow Amount: %.2f, Tree Snowiness: %.2f, Month: %d, Time: %d"),
92 Fog,
98 Month,
99 Time
100 );
101 }

Referenced by AWeather::SendWeatherData().

Member Data Documentation

◆ Cloudiness

float FWeatherParameters::Cloudiness = 0.05f

Definition at line 25 of file WeatherParameters.h.

◆ Fog

float FWeatherParameters::Fog = 0.0f

Definition at line 28 of file WeatherParameters.h.

◆ FogFalloff

float FWeatherParameters::FogFalloff = 0.2f

Definition at line 31 of file WeatherParameters.h.

◆ Month

int FWeatherParameters::Month = 7

Definition at line 46 of file WeatherParameters.h.

Referenced by AWeather::GetCurrentSeason().

◆ Precipitation

float FWeatherParameters::Precipitation = 0.0f

Definition at line 19 of file WeatherParameters.h.

Referenced by LidarNoiseModel::CheckSnowflakeHit().

◆ PrecipitationParticleSize

float FWeatherParameters::PrecipitationParticleSize = 1.0f

Definition at line 22 of file WeatherParameters.h.

Referenced by LidarNoiseModel::CheckSnowflakeHit().

◆ SnowAmount

float FWeatherParameters::SnowAmount = 0.0f

Definition at line 40 of file WeatherParameters.h.

Referenced by ALidar::OnWeatherChanged().

◆ Temperature

float FWeatherParameters::Temperature = 10.0f

Definition at line 16 of file WeatherParameters.h.

◆ Time

int FWeatherParameters::Time = 12

Definition at line 49 of file WeatherParameters.h.

◆ TreeSnowiness

float FWeatherParameters::TreeSnowiness = 0.0f

Definition at line 43 of file WeatherParameters.h.

◆ WindDirection

float FWeatherParameters::WindDirection = 15.0f

Definition at line 37 of file WeatherParameters.h.

◆ WindIntensity

float FWeatherParameters::WindIntensity = 0.0f

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