pub struct AudioTrackConstraints {
pub device_id: Option<ConstrainString<String>>,
pub required: bool,
pub auto_gain_control: Option<ConstrainBoolean>,
pub noise_suppression: Option<ConstrainBoolean>,
pub noise_suppression_level: Option<NoiseSuppressionLevel>,
pub echo_cancellation: Option<ConstrainBoolean>,
pub high_pass_filter: Option<ConstrainBoolean>,
}Expand description
Constraints applicable to audio tracks.
Fields§
§device_id: Option<ConstrainString<String>>Identifier of the device generating the content for the media track.
required: boolImportance of this AudioTrackConstraints.
If true then without this AudioTrackConstraints call session
can’t be started.
auto_gain_control: Option<ConstrainBoolean>Automatically manages changes in the volume of its source media to maintain a steady overall volume level.
noise_suppression: Option<ConstrainBoolean>Indicator whether to enable noise suppression to reduce background sounds.
noise_suppression_level: Option<NoiseSuppressionLevel>Sets the level of aggressiveness for noise suppression if enabled.
NOTE: Only supported on desktop platforms.
echo_cancellation: Option<ConstrainBoolean>Indicator whether to automatically enable echo cancellation to prevent feedback.
high_pass_filter: Option<ConstrainBoolean>Indicator whether to enable a high-pass filter to eliminate low-frequency noise.
NOTE: Only supported on desktop platforms.
Implementations§
Source§impl AudioTrackConstraints
impl AudioTrackConstraints
Sourcepub fn new() -> Self
pub fn new() -> Self
Creates new AudioTrackConstraints with none constraints configured.
Sourcepub async fn satisfies<T: AsRef<MediaStreamTrack>>(&self, track: T) -> bool
pub async fn satisfies<T: AsRef<MediaStreamTrack>>(&self, track: T) -> bool
Checks whether the provided platform::MediaStreamTrack satisfies the
contained constraints.
Sourcepub fn merge(&mut self, another: Self)
pub fn merge(&mut self, another: Self)
Merges these AudioTrackConstraints with another ones, meaning that
if some constraints are not set on these ones, then they will be applied
from another.
Sourcepub const fn required(&self) -> bool
pub const fn required(&self) -> bool
Returns an importance of these AudioTrackConstraints.
If these AudioTrackConstraints are important then without them a
session call can’t be started.
Trait Implementations§
Source§impl Clone for AudioTrackConstraints
impl Clone for AudioTrackConstraints
Source§fn clone(&self) -> AudioTrackConstraints
fn clone(&self) -> AudioTrackConstraints
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more