W3C home > Mailing lists > Public > public-audio@w3.org > April to June 2012

Re: Web Audio API questions and comments

From: Raymond Toy <rtoy@google.com>
Date: Thu, 21 Jun 2012 11:04:06 -0700
Message-ID: <CAE3TgXF7Kjp6fp-AmpeRrk3b+eQ=xj35NA_00c+tFXT=w05Dpg@mail.gmail.com>
To: Joe Turner <joe@oampo.co.uk>
Cc: Chris Rogers <crogers@google.com>, public-audio@w3.org
On Thu, Jun 21, 2012 at 3:08 AM, Joe Turner <joe@oampo.co.uk> wrote:

>
> creating the equivalent to variables?  So say I wanted to add a dc
> offset of 50 to a signal, am I expected to use a JavaScriptAudioNode
> which outputs 50s, waveshape an oscillator so it outputs 1 and use an
> AudioGainNode to scale it up to 50, or do something else clever which
> I haven't thought of?


Another way is to create an AudioBufferSourceNode with a buffer whose
contents are 50 and make it loop (if you want it to loop forever).

Ray
Received on Thursday, 21 June 2012 18:04:54 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Thursday, 21 June 2012 18:05:01 GMT