#include <uwphysicalnoise.h>
Definition at line 46 of file uwphysicalnoise.h.
◆ UnderwaterPhysicalNoise()
UnderwaterPhysicalNoise::UnderwaterPhysicalNoise |
( |
| ) |
|
◆ ~UnderwaterPhysicalNoise()
virtual UnderwaterPhysicalNoise::~UnderwaterPhysicalNoise |
( |
| ) |
|
|
virtualdefault |
◆ addNoiseSource()
It adds the noise emitter corresponding to the given id.
- Parameters
-
size_t | ID of the emitter |
double | Length of the vessel |
ShipCategory | Category of the vessel |
Position* | Pointer to the position of the emitter |
Definition at line 114 of file uwphysicalnoise.cpp.
◆ command()
int UnderwaterPhysicalNoise::command |
( |
int |
argc, |
|
|
const char *const * |
argv |
|
) |
| |
|
overridevirtual |
TCL command interpreter.
It implements the following OTcl methods:
- Parameters
-
argc | Number of arguments in argv. |
argv | Array of strings which are the command parameters (Note that argv[0] is the name of the object). |
- Returns
- TCL_OK or TCL_ERROR whether the command has been dispatched successfully or not.
Reimplemented from UnderwaterPhysical.
Definition at line 71 of file uwphysicalnoise.cpp.
◆ getNoisePower()
double UnderwaterPhysicalNoise::getNoisePower |
( |
Packet * |
p | ) |
|
|
overrideprotectedvirtual |
Compute the noise power, considering also vessels noise if needed.
- Parameters
-
Packet* | pointer to the packet received |
- Returns
- double Total noise power
Definition at line 224 of file uwphysicalnoise.cpp.
◆ getSpeedKnots()
double UnderwaterPhysicalNoise::getSpeedKnots |
( |
Position * |
p | ) |
const |
|
protectedvirtual |
Compute the speed of the vessel in knots.
- Parameters
-
Position* | pointer to the position. |
- Returns
- double Speed of a vessel in m/s
Definition at line 209 of file uwphysicalnoise.cpp.
◆ removeNoiseSourcefromID()
void UnderwaterPhysicalNoise::removeNoiseSourcefromID |
( |
size_t |
id | ) |
|
|
virtual |
It removes the noise emitter corresponding to the given id.
- Parameters
-
Definition at line 133 of file uwphysicalnoise.cpp.
◆ vesselNoisePower()
double UnderwaterPhysicalNoise::vesselNoisePower |
( |
Packet * |
p | ) |
|
|
virtual |
It calculates the total noise power, iterating on the vessel map.
- Parameters
-
Packet* | Pointer to the packet that is going to be received |
- Returns
- double Total vessels noise power
Definition at line 142 of file uwphysicalnoise.cpp.
◆ debug_noise
int UnderwaterPhysicalNoise::debug_noise |
|
protected |
◆ granularity
double UnderwaterPhysicalNoise::granularity |
|
protected |
◆ MS_TO_KNOTS
constexpr const double UnderwaterPhysicalNoise::MS_TO_KNOTS |
|
staticconstexpr |
◆ noise_src
std::vector<Noisesource> UnderwaterPhysicalNoise::noise_src |
|
protected |
◆ ship_stop
int UnderwaterPhysicalNoise::ship_stop |
|
protected |
If enabled, the speed is set to zero when the ship reaches its destination.
Definition at line 132 of file uwphysicalnoise.h.
The documentation for this class was generated from the following files: