support webdirt in minirepl

+ add section in tutorial
This commit is contained in:
Felix Roos 2022-05-29 11:51:26 +02:00
parent a996a7043d
commit 17fa8d904e
5 changed files with 93 additions and 93 deletions

View file

@ -17,9 +17,11 @@ export function loadWebDirt(config) {
}
/**
*
* Uses [webdirt](https://github.com/dktr0/WebDirt) as output.
*
* Supported Webdirt controls:
* <details>
* <summary>show supported Webdirt controls</summary>
*
* - s :: String, -- name of sample bank (ie. old-style with sampleMap)
* - n :: Int, -- number of sample within a bank (ie. old-style with sampleMap)
@ -50,7 +52,13 @@ export function loadWebDirt(config) {
* - coarse :: Number,
* - unit :: String
*
* </details>
*
* @name webdirt
* @memberof Pattern
* @returns Pattern
* @example
* s("bd*2 hh sd hh").n("<0 1>").webdirt()
*/
Pattern.prototype.webdirt = function () {
// create a WebDirt object and initialize Web Audio context