Variable-length index list into buffer (w peek~ /poke~) with interpolation ?

Karel's icon

Karel

10月 11 2024 | 11:27 午後

Hi, I'm looking for a specific way to put data from an itable or multislider into a buffer.

The list from itable could look like
0 0.0173 1 0.1633 2 0.2395 3 ...
and has a variable index length.

This data should be put into a audio-rate-resolution buffer (with peek~ or poke~ ?),
but the data has to be interpolated across the new resolution and preferably the interpolation function is variable.
So possibly, lots of interpolated values are generated based on just a few input values.

So the point is to create a custom buffer, using XY-pad input that has a variable amount of X-values.

Source Audio's icon

Source Audio

10月 12 2024 | 7:14 午前

if you know table length, set buffer size using samples

Karel's icon

Karel

10月 12 2024 | 12:48 午後

if you know table length, set buffer size using samples

(Now edited the question) I should have specified: the buffer size should be fixed at audio rate, which is a much higher resolution than the input data, therefore the question about interpolation.

Anyone know a technique or formula for that? Preferably with a variable interpolation function and variable input index length.

Source Audio's icon

Source Audio

10月 12 2024 | 3:39 午後

you can of course create a signal and record it into buffer in real time,

for example :

Max Patch
Copy patch and select New From Clipboard in Max.

if you want non real time option, try sliding at sample count using line, peek~ etc

Karel's icon

Karel

10月 23 2024 | 1:38 午前

Hey, thanks for suggesting the use of function, here's the result.

Max Patch
Copy patch and select New From Clipboard in Max.

I arrived at one last confusion: how to eliminate clicks using line~.
Because I'm using cycle~ as a flexible window tool, the audio of course clicks whenever I change the window buffer.
I thought I had seen line~ used somewhere, where's it's always interpolating a signal, in order to eliminate clicks. Maybe I dreamt it.
Please see the patch, I think it's clear what I'm trying to do? But it's not working.