예제
구문
p5.Oscillator([frequency], [type])
매개변수
메서드
Returns the value of output gain
Returns the value of frequency of oscillator
Returns current type of oscillator eg. 'sine', 'triangle', 'sawtooth' or 'square'.
Connect to a p5.sound / Web Audio object.
Disconnect all outputs
Pan between Left (-1) and Right (1)
Returns the current value of panPosition , between Left (-1) and Right (1)
Add a value to the p5.Oscillator's output amplitude, and return the oscillator. Calling this method again will override the initial add() with a new value.
Multiply the p5.Oscillator's output amplitude by a fixed value (i.e. turn it up!). Calling this method again will override the initial mult() with a new value.
Scale this oscillator's amplitude values to a given range, and return the oscillator. Calling this method again will override the initial scale() with new values.