From c4b482634f0b7897ec4a33e3b60c2bd298719fb1 Mon Sep 17 00:00:00 2001 From: Felix Roos Date: Sun, 25 Sep 2022 23:35:30 +0200 Subject: [PATCH] doc: begin end --- packages/core/controls.mjs | 9 ++++++--- tutorial/tutorial.mdx | 4 ++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/packages/core/controls.mjs b/packages/core/controls.mjs index f8dfd6c0..6b669660 100644 --- a/packages/core/controls.mjs +++ b/packages/core/controls.mjs @@ -147,10 +147,12 @@ const generic_params = [ /** * a pattern of numbers from 0 to 1. Skips the beginning of each sample, e.g. `0.25` to cut off the first quarter from each sample. * + * @memberof Pattern * @name begin * @param {number | Pattern} amount between 0 and 1, where 1 is the length of the sample * @example - * s("rave").begin("<0 .25 .5 .75>").osc() + * samples({ rave: 'rave/AREUREADY.wav' }, 'github:tidalcycles/Dirt-Samples/master/') + * s("rave").begin("<0 .25 .5 .75>").out() * */ [ @@ -159,12 +161,13 @@ const generic_params = [ 'a pattern of numbers from 0 to 1. Skips the beginning of each sample, e.g. `0.25` to cut off the first quarter from each sample.', ], /** - * The same as {@link begin}, but cuts off the end off each sample. + * The same as .begin, but cuts off the end off each sample. * + * @memberof Pattern * @name end * @param {number | Pattern} length 1 = whole sample, .5 = half sample, .25 = quarter sample etc.. * @example - * s("bd*2,ho*4").end("<.1 .2 .5 1>").osc() + * s("bd*2,ho*4").end("<.1 .2 .5 1>").out() * */ [ diff --git a/tutorial/tutorial.mdx b/tutorial/tutorial.mdx index 3f36c469..3ab09171 100644 --- a/tutorial/tutorial.mdx +++ b/tutorial/tutorial.mdx @@ -367,6 +367,10 @@ The sampler will always pick the closest matching sample for the current note! ## Sampler Effects +{{ 'Pattern.begin' | jsdoc }} + +{{ 'Pattern.end' | jsdoc }} + {{ 'Pattern.loopAt' | jsdoc }} {{ 'Pattern.chop' | jsdoc }}