tags: mus-407 digital-audio audio audio-programming
Digital Delay Line
A digital delay line (DDL) is a type of [audio signal] processing that digitally implements a [delay line]. It stores a sequence of [audio samples] in memory and outputs them after a period of time.
- can be any period of time
Mixing delayed output with input produces a variety of effects:
- echo
- [multi-tap delay]
- [comb filters] & resonators
- [phasing] & [flanging]
- [chorus]
- [pitch-shifting and harmonization]
- [reverberation], simulation of room acoustics
These effects are split between [fixed delays] and [variable delays].
Analog vs Digital Delay Lines
Analog delay:
- implemented via reel-to-reel tape deck
- delay time determined by tape speed & physical distance between record/play heads
- multiple delays possible with multiple play heads and/or multiple tape decks
Digital Delay:
- any number of samples in length
- quantity and length of delays limited by available memory
- flexible in terms of physical space
Signal Flow
Basic DDL (inherently stable):
Basic DDL with [feedback] (unstable if delayed signal [amplitude] > 1):
Delays in Parallel/Series
Parallel: multiple copies are individually sent through multiple delays; outputs are summed
Series: signal is sent through a succession of delays; input/output are usually mixed at each stage
Implementation
Uses a [circular queue] or circular buffer
- a block of memory are treated as if the end and beginning are connected (visually a circle)
- list of sequential memory locations for audio samples
- has a write pointer at and least one read pointer
- read pointer also called a tap
- pointers advance through a buffer, R lags behind W by # of samples corresponding to delay time
- pointers "wrap" around back to beginning when they reach the end of the queue
Digital Filters vs. Digital Delays
In terms of design, digital [filters] & delays are essentially distinguishable
- delay an input signal by some amount
- mix delayed output with input
Filters require delay/mixing in order to cancel/reinforce certain [frequencies].
Consider a simple [lowpass filter]:
$$y[n] = 0.5 \times x[n] + 0.5 \times x[n-1]$$
x
= input signaly
= output signaln
= sample indexx[n]
= input signal atn
th sampley[n]
= output signal atn
th sample
Performs averaging function on consecutive sample pairs
Creates a slight smoothing effect on [waveform] shape, thus attenuating higher frequencies.
For a waveform at [Nyquist frequency], waveform will be completely nullified (consecutive samples are equal and opposite, yielding a zero average)
Longer-term averaging function (ten incremental sample delays in parallel) creates a stronger smoothing effect, lowering the [cutoff frequency]:
$$y[n] = 0.1 \times x[n] + 0.1 \times x[n-1] + ... + 0.1 \times x[n-9]$$
Digital filters and digital delays are closely related in design and result:
- some types of delay lines can noticeably affect a sound's [spectrum]
- some filters can introduce [phase]/timing shifts
- capable of smearing [transients]
General naming distinction:
- delay time measured in [samples] → filter
- delay time measured in seconds/milliseconds → delay line
- related to [linear superposition] and related [wave-interference] properties