paulstretch — Extreme time-stretching algorithm by Nasca Octavian Paul.
The paulstretch opcode is a lightweight implementation of the PaulStretch time-stretching algorithm by Nasca Octavian Paul. It is ideal for timestretching a signal by very large amounts.
The Paulstretch algorithm works very similarly to other STFT-based timestretching methods, using overlap-add with a hanning window. Unique to paulstretch are the use of scrambled phase and very large window sizes (specified in seconds).
istretch -- Stretch factor.
iwindowsize -- Window size, in seconds.
ift -- source signal function table. Deferred-allocation tables (see GEN01) are accepted, but the opcode expects a mono source.
Here is an example of the paulstretch opcode. It uses the file paulstretch.csd
Example 631. Example of the paulstretch opcode.
<CsoundSynthesizer> <CsOptions> -o paulstretch.wav -W </CsOptions> <CsInstruments> sr = 44100 ksmps = 100 0dbfs = 1 nchnls = 2 giwav ftgen 0, 0, 0, 1, "fox.wav", 0, 0, 1 instr 1 aout paulstretch 10, 0.2, giwav outs aout, aout endin </CsInstruments> <CsScore> i1 0 30 </CsScore> </CsoundSynthesizer>