Dynamic view of bpatcher

The bptatcher object allows you to show a view of a portion of a subpatch inside the main patch.

You can change the visible portion of the bpatcher with an offset message to a thispatcher object in the bpatcher's subpatch, and you can change the size of your bpatcher with a script size message to a thispatcher object in the parent patch.

Append data to coll

A reasonable way to append an item in the coll object is to keep track of the last or highest index. This can be done using a counter object or an i (int) object just above coll. Then increment the counter or by one each time you add a new item to the coll object.

Smooth Output of Peakamp~

The peakamp~ object can be used to take the amplitude of one signal and have it control the amplitude of another. Peakamp~ takes a low-frequency sample of the peak amplitude of the signal, which is then smoothed by the line~ object. This gives an intuitively much more accurate representation of the audio signal one is envelope-following than does smoothing the audio signal itself, which tends to smooth out — and thus lose — all the more interesting characteristics of the signal. Here’s an example that lets you compare.

Sigmoid vs Sinusoid acceleration control

You can calculate the desired acceleration/deceleration curve using expr. The smoothest acceleration/deceleration is exhibited by simple harmonic motion (like the swinging of a pendulum), which would be a sinusoidal curve rather than a sigmoid curve (and a sigmoid is theoretically asymptotic, i.e. never truly reaches its goal). You can calculate either with expr. Here’s an example comparing the two.