Gazebo Sim

API Reference

9.0.0
LogicalAudio.hh File Reference
#include <string>
#include <gz/sim/components/LogicalAudio.hh>
#include <gz/sim/config.hh>
#include <gz/sim/logicalaudiosensorplugin-system/Export.hh>
#include <gz/math/Pose3.hh>

Go to the source code of this file.

Namespaces

namespace  gz
 This library is part of the Gazebo project.
 
namespace  gz::sim
 Gazebo is a leading open source robotics simulator, that provides high fidelity physics, rendering, and sensor simulation.
 
namespace  gz::sim::logical_audio
 

Functions

GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE double computeVolume (bool _playing, AttenuationFunction _attenuationFunc, AttenuationShape _attenuationShape, double _sourceEmissionVolume, double _innerRadius, double _falloffDistance, const gz::math::Pose3d &_sourcePose, const gz::math::Pose3d &_targetPose)
 Computes the volume level of an audio source at a certain location.
 
GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE bool detect (double _volumeLevel, double _volumeDetectionThreshold)
 Determines if an audio device can detect volume at a certain level.
 
GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE void setAttenuationFunction (AttenuationFunction &_attenuationFunc, std::string _str)
 Set the attenuation function that matches the defined string. The string is not case sensitive, and must match the spelling of the values in AttenuationFunction. If the spelling does not match, the attenuation function is set as AttenuationFunction::Undefined.
 
GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE void setAttenuationShape (AttenuationShape &_attenuationShape, std::string _str)
 Set the attenuation shape that matches the defined string. The string is not case sensitive, and must match the spelling of the values in AttenuationShape. If the spelling does not match, the attenuation shape is set as AttenuationShape::Undefined.
 
GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE void validateInnerRadiusAndFalloffDistance (double &_innerRadius, double &_falloffDistance)
 Validate the inner radius and falloff distance for an audio source.
 
GZ_SIM_LOGICALAUDIOSENSORPLUGIN_SYSTEM_VISIBLE void validateVolumeLevel (double &_volumeLevel)
 Validate a source's emission volume level.