Envelope Application — User Guide
Dynamic amplitude shaping: applies mathematical envelope functions to audio with real-time visualization, comprehensive parameter control, and professional amplitude modulation.
What this does
This script implements comprehensive envelope application — a sophisticated amplitude modulation system that applies mathematical envelope functions to audio with real-time visualization. Unlike simple gain changes, this method provides: (1) 8 envelope types: Linear, Exponential, Sine, Welch, Step, Linen, Percussive, and full ADSR. (2) Mathematical precision: Exact formula-based envelope generation. (3) Real-time visualization: Three-panel display showing original, envelope, and result. (4) Parameter flexibility: Customizable curves, timing, and levels for each envelope type. (5) Professional workflow: Interactive parameter dialogs with sensible defaults. Process analyzes selected sound, generates envelope based on mathematical formulas, applies via IntensityTier multiplication, and displays comprehensive visualization. Result: precise amplitude control with immediate visual feedback and professional-quality dynamic shaping.
Key Features:
- 8 Envelope Types — From simple fades to complex ADSR
- Mathematical Formulas — Precise, reproducible envelope generation
- Three-Panel Visualization — Original, envelope, and result display
- Interactive Parameters — Context-sensitive dialog boxes
- Curve Control — Linear, exponential, and sine shaping options
- Professional Standards — Industry-standard envelope paradigms
Technical Implementation: (1) Sound analysis: Extract duration and sampling frequency from selection. (2) Envelope selection: User chooses from 8 envelope types via dialog. (3) Parameter collection: Context-sensitive dialogs for each envelope type. (4) Formula generation: Build mathematical formula string for visualization. (5) IntensityTier creation: Generate smooth envelope curve with 200 control points. (6) Application: Multiply original sound by envelope using IntensityTier. (7) Visualization: Three-panel display showing original, envelope shape, and result. Key insight: Different envelope types provide distinct perceptual effects—linear fades sound neutral, exponential fades sound more natural, complex envelopes like ADSR create articulated amplitude contours.
Quick start
- In Praat, select exactly one Sound object.
- Run script… →
envelope_application.praat. - Choose Envelope type from 8 options.
- Adjust parameters in the context-sensitive dialog that appears.
- Click OK — envelope applied and three-panel visualization displayed.
- Result named "originalname_enveloped" appears in Objects window.
Envelope Theory
Amplitude Envelope Fundamentals
Mathematical Definition
Envelope as time-varying gain:
Why Multiple Envelope Types?
Perceptual differences:
- Linear: Constant rate of change, neutral perception
- Exponential: Logarithmic perception, more natural to human hearing
- Sine: Smooth acceleration/deceleration, musical quality
- Welch: Parabolic curves, very smooth transitions
- Step: Instant changes, dramatic effects
- Linen/ADSR: Articulated contours, instrument-like behavior
Envelope Mathematics
Core Mathematical Formulas
Fundamental envelope equations:
Mathematical Properties
Continuity and smoothness:
Constant slope throughout
Perceptually mechanical, predictable
Exponential: C⁰ continuous
Changing slope, natural-sounding
Matches human loudness perception
Sine: C¹ continuous (smooth velocity)
Smooth acceleration and deceleration
Musical, pleasing to the ear
Welch: C¹ continuous
Parabolic segments meet smoothly
Very smooth, professional quality
Step: C⁻¹ discontinuous (infinite derivative)
Instant change, dramatic effect
Can cause clicks if not at zero-crossings
Linen/ADSR: Piecewise continuous
Multiple segments with controlled transitions
Articulated, instrument-like behavior
🎵 Perceptual Intuition
Linear fades:
Sound changes at constant rate
Perceptually neutral but can sound mechanical
Good for technical applications
Exponential fades:
Sound changes faster at beginning/end
Matches human loudness perception
Sounds more natural, musical
Sine fades:
Smooth acceleration and deceleration
Musical, pleasing contour
Ideal for musical phrases
Professional Envelope Paradigms
ADSR Envelope Structure
The industry standard for amplitude articulation:
Why ADSR Matters
Perceptual advantages:
- Articulation: Creates clear amplitude contours
- Naturalness: Mimics acoustic instrument behavior
- Expressivity: Parameters control perceptual character
- Standardization: Universal in synthesis and processing
Complete Processing Pipeline
Envelope Types
Basic Envelopes
📈 Simple Amplitude Shapes
Character: Fundamental mathematical curves for basic amplitude control
Parameters: Start level, end level
Best for: Basic fades, simple amplitude shaping
Basic envelope types:
| Envelope | Mathematical Shape | Sonic Character | Typical Use |
|---|---|---|---|
| Linear | Straight line | Neutral, constant rate | Technical fades, equal change |
| Exponential | Exponential curve | Natural, logarithmic | Musical fades, natural sounds |
| Sine | Raised cosine | Smooth, musical | Phrase shaping, smooth transitions |
| Welch | Parabolic segments | Very smooth, professional | Broadcast, film audio |
| Step | Instant change | Dramatic, abrupt | Special effects, instant changes |
Advanced Envelopes
🎛️ Complex Amplitude Articulation
Character: Multi-segment envelopes for sophisticated shaping
Parameters: Multiple timing and level controls
Best for: Instrument-like articulation, complex dynamics
Advanced envelope types:
| Envelope | Segments | Sonic Character | Typical Use |
|---|---|---|---|
| Linen | Attack-Sustain-Release | Simplified articulation | Quick shaping, basic instruments |
| Perc | Attack-Release only | Percussive, impact sounds | Drums, hits, percussive elements |
| ADSR | Attack-Decay-Sustain-Release | Full articulation, expressive | Complex shaping, instrument simulation |
Envelope Selection Guide
🎯 Choosing the Right Envelope
For simple fades: Linear, Exponential, or Sine
For smooth transitions: Welch or Sine
For dramatic effects: Step
For quick articulation: Linen or Perc
For complex shaping: ADSR
Parameters
Basic Envelope Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Start_level | real | 0.1 | Amplitude at start (0-1 typically) |
| End_level | real | 1.0 | Amplitude at end (0-1 typically) |
Step Envelope Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Step_time | real | duration/2 | Time when level change occurs |
| Level_before | real | 0.1 | Amplitude before step time |
| Level_after | real | 1.0 | Amplitude after step time |
Linen Envelope Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Attack_time | real | 0.1 | Time to reach peak level |
| Sustain_time | real | duration-0.3 | Time at peak level |
| Release_time | real | 0.2 | Time to fade from peak to zero |
| Peak_level | real | 1.0 | Maximum amplitude level |
| Curve | option | linear | Segment shaping: linear/exponential/sine |
Percussive Envelope Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Attack_time | real | 0.01 | Very fast attack time |
| Release_time | real | 0.5 | Release/decay time |
| Peak_level | real | 1.0 | Maximum amplitude |
| Curve | real | -4 | Curvature control (negative=convex) |
ADSR Envelope Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| Attack_time | real | 0.02 | Time from silence to peak |
| Decay_time | real | 0.2 | Time from peak to sustain |
| Sustain_level | real | 0.7 | Level during sustain (0-1) |
| Sustain_time | real | duration-0.5 | Duration of sustain phase |
| Release_time | real | 0.28 | Time from sustain to silence |
| Peak_level | real | 1.0 | Maximum amplitude at peak |
| Curve | real | -4 | Curvature for all segments |
Applications
Audio Production
Use case: Professional fades and dynamic control
Technique: Use Exponential or Welch envelopes for natural fades
Example: Exponential fade-out for musical endings
Sound Design
Use case: Creating articulated amplitude shapes
Technique: Use ADSR for instrument-like articulation
Workflow:
- Use Perc envelope for impact sounds
- Use ADSR for sustained instrument simulations
- Use Step envelopes for gating effects
- Combine multiple envelopes on different layers
Music Composition
Use case: Phrase shaping and dynamic expression
Advantages:
- Precise control over amplitude contours
- Visual feedback for exact shaping
- Mathematical consistency across phrases
- Reproducible results
Example: Apply crescendo with Sine envelope for smooth build
Film and Broadcast
Use case: Professional-level automation and transitions
Technique: Use Welch envelopes for ultra-smooth transitions
Application: Dialogue leveling, music bed transitions
Practical Workflow Examples
🎵 Musical Fade Out
Goal: Create natural-sounding musical fade
Settings:
- Envelope: Exponential
- Start_level: 1.0
- End_level: 0.001 (near silence)
- Duration: Last 5 seconds of piece
Result: Natural, musical fade that doesn't call attention to itself
🥁 Percussive Hit
Goal: Shape drum sample for impact and clarity
Settings:
- Envelope: Perc
- Attack_time: 0.001 (instant attack)
- Release_time: 0.3 (medium decay)
- Peak_level: 1.0
- Curve: -2 (slightly convex decay)
Result: Punchy drum hit with controlled decay
🎻 String Instrument Simulation
Goal: Create expressive amplitude contour for sustained sound
Settings:
- Envelope: ADSR
- Attack_time: 0.1 (moderate attack)
- Decay_time: 0.15 (quick decay to sustain)
- Sustain_level: 0.8 (strong sustain)
- Sustain_time: 2.0 (long sustain)
- Release_time: 0.5 (moderate release)
- Peak_level: 1.0
- Curve: -3 (slightly convex curves)
Result: Expressive, instrument-like amplitude envelope
Advanced Techniques
- Layered envelopes: Apply different envelopes to frequency bands
- Envelope sequencing: Apply multiple different envelopes in sequence
- Dynamic control: Use envelope to control other parameters (filter, pitch)
- Reverse envelopes: Apply envelope backwards for special effects
- Envelope modulation: Use one envelope to modulate another's parameters
Combine with other Praat tools for complex processing chains
- Linear: Use when constant rate of change is desired
- Exponential: Use for natural-sounding fades (start_level > end_level)
- Sine: Use for musical phrases and smooth transitions
- Welch: Use for professional broadcast quality
- Step: Use for dramatic changes and gating effects
- Linen: Use for quick instrument-like shaping
- Perc: Use for percussive sounds and impacts
- ADSR: Use for complex, expressive articulation
Troubleshooting Common Issues
Cause: Discontinuous envelope changes, especially with Step type
Solution: Use smoother envelope types, ensure changes at zero-crossings
Cause: Timing parameters exceed sound length
Solution: Adjust timing parameters to fit within duration
Cause: Level parameters set too low or high
Solution: Adjust level parameters, use visualization to check
Cause: Parameter misunderstanding or mathematical mismatch
Solution: Check formulas, use simpler envelopes first to build intuition
Mathematical Deep Dive
Envelope Mathematics
Curve Parameter Implementation
Generalized curve shaping:
Continuity Analysis
Mathematical smoothness: