Set the amplitude between 0 and 1.0. Or, pass in an object such as an oscillator to modulate amplitude with an audio signal.
구문
amp(vol, [rampTime], [timeFromNow])
매개변수
vol
Number|Object:
between 0 and 1.0 or a modulating signal/oscillator
rampTime
Number:
create a fade that lasts rampTime
timeFromNow
Number:
schedule this event to happen seconds from now
Returns
AudioParam: gain If no value is provided, returns the Web Audio API AudioParam that controls this oscillator's gain/amplitude/volume)
Notice any errors or typos? Please let us know. Please feel free to edit lib/addons/p5.sound.js and open a pull request!