Skip to content

Commit fb9e338

Browse files
authored
Merge pull request #759 from UnknownSuperficialNight/agc-edits
docs: Update Recommended `release_time` for `AGC` to `0.0`
2 parents f91f1c3 + ae9f6bc commit fb9e338

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/source/mod.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ pub trait Source: Iterator<Item = Sample> {
313313
/// A recommended attack_time of `4.0` seconds provides a sweet spot for most applications.
314314
///
315315
/// `release_time`:
316-
/// **TL;DR**: Response time for volume decreases. Shorter = faster gain reduction. **Recommended: `0.005` seconds**.
316+
/// **TL;DR**: Response time for volume decreases. Shorter = faster gain reduction. **Recommended: `0.0` seconds**.
317317
///
318318
/// The time (in seconds) for the AGC to respond to input level decreases.
319319
/// This parameter controls how quickly the gain is reduced when the signal level drops.
@@ -323,8 +323,8 @@ pub trait Source: Iterator<Item = Sample> {
323323
/// However, if the release_time is too high, the AGC may not be able to lower the gain
324324
/// quickly enough, potentially leading to clipping and distorted sound before it can adjust.
325325
/// Finding the right balance is crucial for maintaining natural-sounding dynamics and
326-
/// preventing distortion. A recommended release_time of `0.005` seconds often works well for
327-
/// general use, providing a good balance between responsiveness and smooth transitions.
326+
/// preventing distortion. A recommended release_time of `0.0` seconds works well for
327+
/// general use, allowing the AGC to decrease the gain immediately with no delay, ensuring there is no clipping.
328328
///
329329
/// `absolute_max_gain`:
330330
/// **TL;DR**: Maximum allowed gain. Prevents over-amplification. **Recommended: `5.0`**.
@@ -349,7 +349,7 @@ pub trait Source: Iterator<Item = Sample> {
349349
/// let source = SineWave::new(444.0); // An example.
350350
/// let (sink, output) = Sink::new(); // An example.
351351
///
352-
/// let agc_source = source.automatic_gain_control(1.0, 4.0, 0.005, 5.0);
352+
/// let agc_source = source.automatic_gain_control(1.0, 4.0, 0.0, 5.0);
353353
///
354354
/// // Add the AGC-controlled source to the sink
355355
/// sink.append(agc_source);

0 commit comments

Comments
 (0)