1- /*! p5.sound.js v0.3.9 2018-09 -10 */
1+ /*! p5.sound.js v0.3.10 2019-01 -10 */
22/**
33 * p5.sound extends p5 with <a href="http://caniuse.com/audio-api"
44 * target="_blank">Web Audio</a> functionality including audio input,
@@ -6199,7 +6199,7 @@ envelope = function () {
61996199 * var attackLevel = 1.0;
62006200 * var releaseLevel = 0;
62016201 *
6202- * var attackTime = 0.001
6202+ * var attackTime = 0.001;
62036203 * var decayTime = 0.2;
62046204 * var susPercent = 0.2;
62056205 * var releaseTime = 0.5;
@@ -6224,7 +6224,7 @@ envelope = function () {
62246224 * cnv.mousePressed(playEnv);
62256225 * }
62266226 *
6227- * function playEnv(){
6227+ * function playEnv() {
62286228 * env.play();
62296229 * }
62306230 * </code></div>
@@ -6375,7 +6375,7 @@ envelope = function () {
63756375 * var attackLevel = 1.0;
63766376 * var releaseLevel = 0;
63776377 *
6378- * var attackTime = 0.001
6378+ * var attackTime = 0.001;
63796379 * var decayTime = 0.2;
63806380 * var susPercent = 0.2;
63816381 * var releaseTime = 0.5;
@@ -6400,7 +6400,7 @@ envelope = function () {
64006400 * cnv.mousePressed(playEnv);
64016401 * }
64026402 *
6403- * function playEnv(){
6403+ * function playEnv() {
64046404 * env.play();
64056405 * }
64066406 * </code></div>
@@ -6426,7 +6426,7 @@ envelope = function () {
64266426 * var attackLevel = 1.0;
64276427 * var releaseLevel = 0;
64286428 *
6429- * var attackTime = 0.001
6429+ * var attackTime = 0.001;
64306430 * var decayTime = 0.2;
64316431 * var susPercent = 0.2;
64326432 * var releaseTime = 0.5;
@@ -6451,7 +6451,7 @@ envelope = function () {
64516451 * cnv.mousePressed(playEnv);
64526452 * }
64536453 *
6454- * function playEnv(){
6454+ * function playEnv() {
64556455 * env.play();
64566456 * }
64576457 * </code></div>
@@ -6545,7 +6545,7 @@ envelope = function () {
65456545 * var attackLevel = 1.0;
65466546 * var releaseLevel = 0;
65476547 *
6548- * var attackTime = 0.001
6548+ * var attackTime = 0.001;
65496549 * var decayTime = 0.2;
65506550 * var susPercent = 0.2;
65516551 * var releaseTime = 0.5;
@@ -6570,7 +6570,7 @@ envelope = function () {
65706570 * cnv.mousePressed(playEnv);
65716571 * }
65726572 *
6573- * function playEnv(){
6573+ * function playEnv() {
65746574 * // trigger env on triOsc, 0 seconds from now
65756575 * // After decay, sustain for 0.2 seconds before release
65766576 * env.play(triOsc, 0, 0.2);
@@ -6605,7 +6605,7 @@ envelope = function () {
66056605 * var attackLevel = 1.0;
66066606 * var releaseLevel = 0;
66076607 *
6608- * var attackTime = 0.001
6608+ * var attackTime = 0.001;
66096609 * var decayTime = 0.3;
66106610 * var susPercent = 0.4;
66116611 * var releaseTime = 0.5;
@@ -6630,7 +6630,7 @@ envelope = function () {
66306630 * cnv.mousePressed(envAttack);
66316631 * }
66326632 *
6633- * function envAttack(){
6633+ * function envAttack() {
66346634 * console.log('trigger attack');
66356635 * env.triggerAttack();
66366636 *
@@ -6709,7 +6709,7 @@ envelope = function () {
67096709 * var attackLevel = 1.0;
67106710 * var releaseLevel = 0;
67116711 *
6712- * var attackTime = 0.001
6712+ * var attackTime = 0.001;
67136713 * var decayTime = 0.3;
67146714 * var susPercent = 0.4;
67156715 * var releaseTime = 0.5;
@@ -6734,7 +6734,7 @@ envelope = function () {
67346734 * cnv.mousePressed(envAttack);
67356735 * }
67366736 *
6737- * function envAttack(){
6737+ * function envAttack() {
67386738 * console.log('trigger attack');
67396739 * env.triggerAttack();
67406740 *
@@ -8505,7 +8505,6 @@ filter = function () {
85058505 freq = 1 ;
85068506 }
85078507 if ( typeof freq === 'number' ) {
8508- this . biquad . frequency . value = freq ;
85098508 this . biquad . frequency . cancelScheduledValues ( this . ac . currentTime + 0.01 + t ) ;
85108509 this . biquad . frequency . exponentialRampToValueAtTime ( freq , this . ac . currentTime + 0.02 + t ) ;
85118510 } else if ( freq ) {
@@ -10425,14 +10424,14 @@ looper = function () {
1042510424 } ;
1042610425 /**
1042710426 * <p>A p5.Part plays back one or more p5.Phrases. Instantiate a part
10428- * with steps and tatums. By default, each step represents 1/16th note.</p>
10427+ * with steps and tatums. By default, each step represents a 1/16th note.</p>
1042910428 *
1043010429 * <p>See p5.Phrase for more about musical timing.</p>
1043110430 *
1043210431 * @class p5.Part
1043310432 * @constructor
1043410433 * @param {Number } [steps] Steps in the part
10435- * @param {Number } [tatums] Divisions of a beat (default is 1/16, a quarter note)
10434+ * @param {Number } [tatums] Divisions of a beat, e.g. use 1/4, or 0.25 for a quater note (default is 1/16, a sixteenth note)
1043610435 * @example
1043710436 * <div><code>
1043810437 * var box, drum, myPart;
@@ -10511,7 +10510,7 @@ looper = function () {
1051110510 this . metro . setBPM ( tempo , rampTime ) ;
1051210511 } ;
1051310512 /**
10514- * Returns the Beats Per Minute of this currently part.
10513+ * Returns the tempo, in Beats Per Minute, of this part.
1051510514 *
1051610515 * @method getBPM
1051710516 * @return {Number }
@@ -10565,7 +10564,7 @@ looper = function () {
1056510564 } ;
1056610565 } ;
1056710566 /**
10568- * Stop the part and cue it to step 0.
10567+ * Stop the part and cue it to step 0. Playback will resume from the begining of the Part when it is played again.
1056910568 *
1057010569 * @method stop
1057110570 * @param {Number } [time] seconds from now
@@ -10636,8 +10635,7 @@ looper = function () {
1063610635 }
1063710636 } ;
1063810637 /**
10639- * Get a phrase from this part, based on the name it was
10640- * given when it was created. Now you can modify its array.
10638+ * Find all sequences with the specified name, and replace their patterns with the specified array.
1064110639 *
1064210640 * @method replaceSequence
1064310641 * @param {String } phraseName
@@ -10664,7 +10662,7 @@ looper = function () {
1066410662 }
1066510663 } ;
1066610664 /**
10667- * Fire a callback function at every step.
10665+ * Set the function that will be called at every step. This will clear the previous function .
1066810666 *
1066910667 * @method onStep
1067010668 * @param {Function } callback The name of the callback
0 commit comments