Re: Consensus gathering for the Dezippering issue - blink processing

On Wed, 11 Dec 2013 18:13:49 +1300, Karl Tomlinson wrote:

> I had a look at what Blink code does, so I'll post my notes here
> for reference.  (I don't know whether or not this differs from
> Webkit.)
>
> When there are no nodes connected to an AudioParam, changes from
> the value setter are smoothed using a function similar to
> setTargetAtTime() on these nodes:
>
>   BiquadFilterNode and OscillatorNode use a factor of 0.95 per
>   sample interval, [...]

I read this code wrong.  This 0.95 factor is applied only on the
first sample of each block (even for the a-rate parameters on
OscillatorNode).  At 44.1 kHz, the smoothing is roughly equivalent
to using a time constant of 57 ms on a k-rate AudioParam.

>   GainNode uses a factor of 0.995 per sample, which at 44.1 kHz is
>   roughly equivalent to a time constant of 4.5 ms.
>
>   DelayNode uses a time constant of 20 ms, independent of sample
>   rate.
>
> I don't see any smoothing on AudioBufferSourceNode.playbackRate or
> in DynamicsCompressorNode.
>
> There is also smoothing in PannerNode that is not applied to
> AudioParams, but to functions of double attributes.  Cone and
> distance gain are smoothed using a time constant around 4.5 ms at
> 44.1 kHz, and the time constant for smoothing the panning gain is
> 50 ms independent of the sample rate.
>
> In Gecko, the only smoothing of attributes that I know of is on
> DelayNode.

Received on Monday, 23 December 2013 06:04:49 UTC