Subject: Re: [linux-audio-dev] Ideas for AES/LAAGA/whatever (was Re: sound API libraries, servers, etc.)
From: Jim Peters (jim_AT_aguazul.demon.co.uk)
Date: Wed Apr 25 2001 - 23:21:15 EEST
eli+@gs211.sp.cs.cmu.edu wrote:
> Jim Peters wrote:
> > The upshot of this is that control inputs need to be able to switch
> > between constant values and sample-rate values from frame to frame.
>
> A middle ground is often useful: a-rate ugens upsample their k-rate
> inputs through linear interpolation. Call it i-rate. This does delay
> the control data by effectively half the k-rate sampling period. (Can
> we call it a "block"? "Frame" is an audio sample frame to me.)
Yeah, sorry. I was saying `frame' because that's what I thought Paul
was calling a block (as in MP3 frames), but it seems he's calling
samples frames as well, so, block it is.
Regarding a-rate versus k-rate, and how professional synths handle it:
when changes travel over MIDI, they are definitely stepped, and the
rate is nowhere near that of the sample-rate, so pro synths must do
some smoothing automatically to even out the steps. This may be
similar to the interpolation that you describe. I'd like a bit more
control than the CSound style, though, because a sudden step from 100%
amplitude to 50% would sound different at different k-rates with this
approach. At very fast k-rate, you'd still get a nasty click.
The other thing is that with my code, I've been messing around a lot
with sine-waves, so it is really easy to hear the distortion because
there are no higher harmonics to mask it. Maybe you can get away with
less precautions with more complex sounds.
Jim
-- Jim Peters / __ | \ Aguazul / /| /| )| /| / )|| \ jim_AT_aguazul. \ (_|(_|(_|(_| )(_|I / www.aguazul. demon.co.uk \ ._) _/ / demon.co.uk
This archive was generated by hypermail 2b28 : Thu Apr 26 2001 - 01:04:30 EEST