Stretch-Tremolo Ambience — User Guide

Time-stretched textures meet rhythmic pulsation: creates ethereal ambient layers by stretching audio into smooth clouds, then applying tremolo modulation to generate breathing, living soundscapes from any source material.

Author: Shai Cohen Affiliation: Department of Music, Bar-Ilan University, Israel Version: 1.0 (2025) License: MIT License Repo: https://github.com/ShaiCohen-ops/Praat-plugin_AudioTools
Contents:

What this does

This script creates ethereal ambient textures by combining time-stretching with tremolo modulation. It processes audio through a unique two-stage pipeline: first stretching the source material into smooth, sustained "clouds" using phase-vocoder techniques, then applying rhythmic amplitude modulation to create breathing, pulsating textures. The result is a lush ambient layer that can be mixed with the original sound to add depth, space, and atmospheric character to any audio material.

Key Features:

What is stretch-tremolo ambience? Traditional ambience effects use reverb or delay to create space. Stretch-tremolo ambience takes a different approach: it time-stretches audio to create sustained textures, then applies amplitude modulation to make those textures "breathe." This creates ambient layers that are both smooth (from stretching) and rhythmic (from tremolo), producing complex, evolving soundscapes that work particularly well for transforming percussive or transient-rich material into atmospheric pads.

Technical Implementation: (1) Safety preparation: Renames source audio to prevent object reference conflicts. (2) Cloud creation: Converts to mono, applies phase-vocoder stretching using Praat's Lengthen algorithm. (3) Modulation: Applies tremolo to stretched cloud using sine-wave amplitude modulation. (4) Duration management: Crops stretched cloud back to original duration. (5) Mixing: Combines original dry signal with modulated cloud using flexible mix controls. (6) Cleanup: Restores original names and removes temporary objects.

Quick start

  1. In Praat, select exactly one Sound object (any material works).
  2. Run script…stretch_tremolo_ambience.praat.
  3. Choose a Preset or select "Custom" to adjust parameters manually.
  4. Adjust Stretch Parameters:
    • Stretch_factor: Time expansion amount (1.5-8.0)
  5. Set Cloud Modulation for rhythmic character:
    • Cloud_Rate_Hz: Tremolo speed (0.2-6.0 Hz)
    • Cloud_Depth: Modulation intensity (0.2-0.8)
  6. Adjust Mix balances:
    • Dry_Mix: Original signal level (0.0-2.0)
    • Wet_Cloud_Mix: Ambient layer level (0.0-1.0)
  7. Click OK — effect applied, result named "originalname_cloud".
Quick tip: Start with Ethereal Pad for smooth, beautiful textures. Use Ghostly Trail for rhythmic, pulsating effects. Try Dark Drone for deep, sustained atmospheres. Higher stretch factors (4.0-8.0) create smoother, more pad-like textures. Lower stretch factors (1.5-3.0) preserve more of the original character. The effect works wonderfully on percussive sounds—turning drums into pads, or vocal fragments into choirs.
Important: Very high stretch factors (>8.0) may cause processing artifacts or excessive computation time. Extreme cloud depth (>0.8) can cause volume drops or pumping effects. The script converts to mono for stretching but preserves stereo in final output. Complex source material with lots of transients may produce less smooth results. Processing time increases with both stretch factor and original duration—long files with high stretch factors may take considerable time.

Ambience Creation Theory

The Two-Stage Ambience Pipeline

From Source to Soundscape

The effect transforms audio through two distinct processes:

STAGE 1: TIME STRETCHING (Cloud Creation) Input: Original sound with transients and detail Process: Phase-vocoder time expansion Output: Sustained, smooth texture ("cloud") Effect: Removes sharp attacks, creates pad-like quality STAGE 2: AMPLITUDE MODULATION (Breathing Life) Input: Stretched cloud texture Process: Sine-wave tremolo application Output: Rhythmic, pulsating ambience Effect: Adds motion and organic character COMBINED RESULT: Dry original + Modulated cloud = Living soundscape Preserves original identity while adding atmospheric depth

🌫️ Why Stretch Before Modulating?

Traditional approach: Apply modulation to original → rhythmic but detailed

This approach: Stretch first, then modulate → smooth and rhythmic

Key insight: Time-stretching smooths out transients and details, creating a canvas that tremolo can paint with broad, beautiful strokes. The modulation works on the texture rather than the details.

Phase-Vocoder Time Stretching

How Praat's Lengthen Algorithm Works

The phase-vocoder preserves pitch while changing duration:

PHASE-VOCODER PROCESS: 1. Analysis: Break sound into short overlapping frames 2. FFT: Convert each frame to frequency domain 3. Phase manipulation: Adjust phase relationships between frames 4. Overlap-add: Reconstruct stretched signal PRAAT'S LENGTHEN PARAMETERS: Lengthen (overlap-add): 75, 600, stretch_factor Where: 75 Hz = Pitch floor (ignores frequencies below this) 600 Hz = Pitch ceiling (ignores frequencies above this) stretch_factor = Time expansion ratio This method preserves formant structure and harmonic content while smoothly expanding temporal features

Stretch Factor Effects

Stretch factor musical results:

1.5-2.0: Subtle smoothing, preserves most original character
2.0-3.0: Noticeable texture change, good for rhythmic sources
3.0-5.0: Strong pad-like transformation, ideal for ambience
5.0-8.0: Extreme smoothing, creates drone textures
8.0+: Experimental, may produce artifacts

Sweet spot: 3.0-4.0 for most musical applications

Tremolo Modulation Mathematics

Sine-Wave Amplitude Control

The tremolo uses a classic amplitude modulation formula:

TREMOLO FORMULA: output = input × [1 - depth × (1 + sin(2π × rate × t)) / 2] Where: depth = cloud_Depth (0.0-1.0) rate = cloud_Rate_Hz (oscillations per second) t = time in seconds BEHAVIOR: When depth = 0.0: No modulation (output = input) When depth = 0.5: Modulation between 0.75 and 0.25 of original When depth = 1.0: Modulation between 1.0 and 0.0 (full to silence) The (1 + sin(...))/2 term creates a unipolar modulation that oscillates between 0 and 1 rather than -1 and 1

Rate and Depth Combinations

Modulation character by settings:

Slow + Deep (0.2 Hz, 0.7 depth): Breathing, oceanic motion
Medium + Medium (2.0 Hz, 0.5 depth): Gentle pulsation
Fast + Shallow (6.0 Hz, 0.3 depth): Nervous, shimmering
Very Slow + Very Deep (0.1 Hz, 0.9 depth): Swelling, dramatic

Musical rates:
0.5-1.0 Hz: Largo, very slow breathing
1.0-2.0 Hz: Adagio, relaxed pulse
2.0-4.0 Hz: Andante, walking pace
4.0-6.0 Hz: Allegro, energetic pulse

Stretch Technique

⏱️ Phase-Vocoder Time Stretching

How time-stretching creates ambience:

Original Sound: [attack] [sustain] [release] After 3× Stretch: [attaaaaaaaack] [suuuuustaaaaain] [releeeeease] The phase-vocoder: - Preserves harmonic relationships (pitch unchanged) - Smoothes transients and sharp attacks - Creates overlapping texture from short events - Turns rhythmic patterns into sustained pads Musical transformation: Drums → Atmospheric textures Speech → Choir-like pads Percussion → Rhythmic beds Short sounds → Sustained tones

Why mono for stretching?

  • Ensures phase coherence between channels
  • Prevents stereo image smearing
  • More computationally efficient
  • Final mix preserves original stereo

Complete Processing Pipeline

🔄 Step-by-Step Processing

STEP 1: Safety Preparation

Original Sound → Rename to "SourceAudio_Temp" Purpose: Prevents Praat object naming conflicts in formulas

STEP 2: Cloud Layer Creation

Convert to mono → Remove stereo information Lengthen (overlap-add): 75, 600, stretch_factor Result: Time-expanded mono cloud

STEP 3: Tremolo Application

Apply formula: self × [1 - depth × (1 + sin(2π×rate×t))/2] Result: Rhythmic, pulsating cloud texture

STEP 4: Duration Management

Extract part: 0, original_duration, "rectangular", 1, "no" Rename to "CloudAudio_Temp" Purpose: Crops stretched sound back to original length

STEP 5: Final Mix

Copy original → Apply mix formula: output = dry_signal × dry_Mix + cloud_signal × wet_Cloud_Mix Result: Combined dry+wet with preserved stereo image

STEP 6: Cleanup

Remove temporary objects Restore original sound name Normalize output peak

Source Material Considerations

What Works Best for Stretch-Tremolo

Ideal source material:

Percussive sounds: Drums, hits, clicks → Smooth textures
Vocal fragments: Words, syllables → Choir-like pads
Instrument sustains: Strings, synths → Enhanced atmospheres
Environmental sounds: Water, wind → Dreamy textures
Short melodic phrases: Riffs, motifs → Evolving pads

Less ideal material:
Already sustained sounds → Less transformation
Very noisy material → May become muddled
Complex polyphonic music → Can become chaotic

Effect Presets

Ethereal Pad (Smooth)

✨ Smooth Textural Transformation

Settings: Stretch: 4.0, Rate: 0.5 Hz, Depth: 0.3, Wet Mix: 0.5

Character: Beautiful, smooth pad textures with gentle breathing motion

Best for: Creating lush pads from any source material

Ghostly Trail (Slow pulse)

👻 Rhythmic Atmospheric Pulses

Settings: Stretch: 2.5, Rate: 4.0 Hz, Depth: 0.6, Wet Mix: 0.4

Character: Pulsating, rhythmic trails with medium texture

Best for: Adding motion to sounds, creating rhythmic beds

Dark Drone (Deep stretch)

🌑 Deep Sustained Atmospheres

Settings: Stretch: 8.0, Rate: 0.2 Hz, Depth: 0.2, Wet Mix: 0.7

Character: Very smooth, deep drone textures with subtle motion

Best for: Background atmospheres, deep textural beds

Shimmering Tail (Fast wobble)

💎 Nervous, Sparkling Textures

Settings: Stretch: 3.0, Rate: 6.0 Hz, Depth: 0.5, Wet Mix: 0.4

Character: Fast, shimmering modulation with preserved detail

Best for: Adding sparkle and motion, special effects

PresetStretchRate (Hz)DepthWet MixTextureMotion
Ethereal Pad4.00.50.30.5Very SmoothSlow Breathing
Ghostly Trail2.54.00.60.4MediumRhythmic Pulse
Dark Drone8.00.20.20.7Ultra SmoothVery Slow
Shimmering Tail3.06.00.50.4DetailedFast Shimmer

Parameters

Stretch Parameters

ParameterTypeRangeDefaultDescription
Stretch_factorpositive1.5-8.03.0Time expansion ratio

Cloud Modulation

ParameterTypeRangeDefaultDescription
Cloud_Rate_Hzpositive0.2-6.02.0Tremolo oscillation frequency
Cloud_Depthpositive0.2-0.80.5Modulation intensity

Mix Parameters

ParameterTypeRangeDefaultDescription
Dry_Mixpositive0.0-2.01.0Original signal level
Wet_Cloud_Mixpositive0.0-1.00.6Ambient layer level

Output Options

ParameterTypeRangeDefaultDescription
Scale_peakpositive0.1-1.00.99Output normalization level
Play_after_processingbooleanyes/noyesAuto-play processed sound

Parameter Interactions

Creative parameter combinations:

High Stretch + Low Rate + Medium Depth:
Creates slowly breathing, very smooth pads

Medium Stretch + High Rate + High Depth:
Creates nervous, pulsating textures

Low Stretch + Medium Rate + Low Depth:
Adds subtle motion while preserving detail

Extreme Stretch + Very Low Rate + Low Depth:
Creates nearly static, deep atmospheric beds

Mix balance strategies:
Dry 1.0 + Wet 0.3: Subtle enhancement
Dry 0.5 + Wet 0.7: Strong ambience character
Dry 0.0 + Wet 1.0: Pure ambient texture

Applications

Sound Design and Textures

Use case: Creating custom atmospheric textures from everyday sounds

Technique: Process unexpected source material

Source ideas:

Result: Unique, custom atmospheric layers

Music Production Enhancement

Use case: Adding depth and space to musical elements

Technique: Process individual tracks or stems

Applications:

Result: Enhanced productions with added atmospheric depth

Film and Game Audio

Use case: Creating ambient beds and environmental sounds

Technique: Process location recordings or Foley

Creative approaches:

Result: Custom, layered ambient soundscapes

Experimental Music and Composition

Use case: Transforming musical material into new textures

Technique: Use as a compositional tool

Compositional strategies:

Result: Innovative textural compositions

Practical Workflow Examples

🎵 Drum Loop Transformation

Goal: Turn drum loop into atmospheric bed

Settings:

  • Preset: Ethereal Pad
  • Increase stretch to 5.0 for more smoothing
  • Reduce wet mix to 0.4 to preserve rhythm
  • Apply to entire drum loop

Result: Drum loop with atmospheric texture layer

🎤 Vocal Pad Creation

Goal: Create choir-like pad from spoken word

Settings:

  • Preset: Dark Drone
  • Use stretch 6.0 for maximum smoothing
  • Set wet mix to 0.8 for strong effect
  • Process individual words or phrases

Result: Vocal-derived pad textures

🎬 Environmental Atmosphere

Goal: Create custom environment bed

Settings:

  • Preset: Ghostly Trail
  • Adjust rate to match desired pulse speed
  • Use medium stretch (3.0-4.0)
  • Process location recordings

Result: Custom atmospheric background

Advanced Techniques

Layered processing:
  • Process same source with different presets
  • Layer Ethereal Pad + Ghostly Trail for complex motion
  • Use different stretch factors for frequency separation
  • Create evolving textures by automating parameters
Source preparation:
  • Pre-process sounds with EQ before stretching
  • Use transient-rich sounds for maximum transformation
  • Experiment with unconventional source material
  • Combine multiple short sounds before processing

Troubleshooting Common Issues

Problem: Artifacts or glitches in stretched sound
Cause: Too high stretch factor, complex source material
Solution: Reduce stretch factor, try simpler source sounds
Problem: Output too washed out or unclear
Cause: Too high wet mix, extreme stretch factor
Solution: Reduce wet mix, use lower stretch factor
Problem: Tremolo too obvious or distracting
Cause: Too high cloud depth, inappropriate rate
Solution: Reduce cloud depth, adjust rate for material
Problem: Processing takes too long
Cause: High stretch factor with long duration
Solution: Reduce stretch factor, process shorter segments

Technical Deep Dive

Phase-Vocoder Algorithm

Praat's Lengthen Implementation

The phase-vocoder uses sophisticated time-scale modification:

PRAAT LENGTHEN ALGORITHM: Input: Sound signal s(t) Parameters: Pitch floor (75 Hz), Pitch ceiling (600 Hz), Stretch factor (α) PROCESS: 1. Pitch analysis: Detect fundamental frequency and harmonics 2. Frame decomposition: Break into overlapping analysis frames 3. Phase propagation: Adjust phase relationships for time expansion 4. Resynthesis: Overlap-add reconstructed frames MATHEMATICAL BASIS: Uses the sinusoidal model: s(t) = Σ Aₖ(t) cos(φₖ(t)) Where phase φₖ(t) is carefully manipulated to preserve harmonic relationships while changing duration

Quality vs Speed Trade-offs

Algorithm performance characteristics:

Quality factors:
- Pitch floor/ceiling settings affect harmonic preservation
- Frame size and overlap affect transient handling
- Phase propagation method affects smoothness

Computational load:
- Increases with stretch factor
- Higher quality settings require more processing
- Long files with high stretch = significant computation

Praat's approach: Optimized for speech but works well for general audio

Mixing and Signal Flow

Preserving Stereo Image

The script carefully manages stereo information:

STEREO HANDLING STRATEGY: Original: May be mono or stereo Cloud processing: Always converted to mono for stretching Final mix: Uses [col] indexing for channel compatibility MIX FORMULA: output = dry_signal × dry_Mix + cloud_signal[col] × wet_Cloud_Mix The [col] index: - For mono original: cloud_signal[1] (single channel) - For stereo original: cloud_signal[1] for left, cloud_signal[2] for right - Preserves original stereo image while adding mono cloud layer Result: Stereo original + Mono cloud = Enhanced stereo output

Creative Extensions

Beyond the Basic Effect

Advanced creative possibilities: The stretch-tremolo concept can be extended in numerous ways. Try processing different frequency bands separately with different stretch factors. Automate the stretch factor over time to create evolving textures. Use the effect in feedback loops for self-generating textures. Combine with other effects like reverb or filtering for even more complex results. The basic two-stage process (stretch + modulate) provides a foundation for endless creative exploration.

Integration with Other Effects

Effect chain possibilities:

Before stretch-tremolo:
EQ → Shape frequency content before stretching
Filter → Remove unwanted frequencies
Pitch shift → Create harmonic variations

After stretch-tremolo:
Reverb → Add additional space and depth
Delay → Create rhythmic patterns
Filter → Shape the final texture
Compression → Control dynamics

Parallel processing:
Multiple instances with different settings
Frequency-split processing
Temporal gating for rhythmic effects