Forums > MaxMSP

'group' samples ?

February 21, 2007 | 12:21 pm

Hi ppl,

Is there any way to ‘group’ a certain number of samples from a buffer?
For example if I use a multislider with 16 sliders and a buffer with 512 samples, how can I set the first slider to the first 32 samples (512/16), the second slider to samples 32-64, etc..?
Apologise for my broken English, I hope you understand my question.

many thanks,
Mike


February 21, 2007 | 1:33 pm

On 21 Feb 2007, at 13:21, michael wrote:

>
> Hi ppl,
>
> Is there any way to ‘group’ a certain number of samples from a buffer?
> For example if I use a multislider with 16 sliders and a buffer
> with 512 samples, how can I set the first slider to the first 32
> samples (512/16), the second slider to samples 32-64, etc..?

you could try something like this.
volker.

#P window setfont "Sans Serif" 9.;
#P user waveform~ 298 280 363 150 3 9;
#W mode select;
#W mouseoutput continuous;
#W unit samples;
#W grid 22.675737;
#W ticks 0;
#W labels 1;
#W vlabels 0;
#W vticks 1;
#W bpm 120. 4.;
#W frgb 33 0 0;
#W brgb 60 178 173;
#W rgb2 0 95 255;
#W rgb3 0 0 0;
#W rgb4 0 0 0;
#W rgb5 190 137 255;
#W rgb6 100 100 100;
#W rgb7 100 100 100;
#P window linecount 1;
#P newex 94 266 66 196617 t b l;
#P newex 124 352 27 196617 – 1;
#P newex 124 374 36 196617 +;
#P hidden newex 297 241 48 196617 loadbang;
#P newex 182 422 67 196617 buffer~ b 12;
#P hidden message 297 262 32 196617 set b;
#P newex 150 330 32 196617 * 32;
#P newex 150 301 61 196617 unpack 0 0.;
#P newex 124 395 87 196617 pack 0 0.;
#P newex 94 241 52 196617 listfunnel;
#P newex 94 330 40 196617 uzi 32;
#P newex 125 424 44 196617 peek~ b;
#P user multiSlider 94 91 203 141 -1. 1. 16 2681 15 1 0 2 0 33 0;
#M frgb 0 0 0;
#M brgb 255 255 255;
#M rgb2 127 127 127;
#M rgb3 0 0 0;
#M rgb4 37 52 91;
#M rgb5 74 105 182;
#M rgb6 112 158 18;
#M rgb7 149 211 110;
#M rgb8 187 9 201;
#M rgb9 224 62 37;
#M rgb10 7 114 128;
#P connect 0 0 3 0;
#P connect 5 0 6 0;
#P connect 5 1 4 1;
#P connect 4 0 1 0;
#P connect 6 0 10 1;
#P connect 10 0 4 0;
#P connect 2 2 11 0;
#P connect 11 0 10 0;
#P connect 3 0 12 0;
#P connect 12 1 5 0;
#P connect 12 0 2 0;
#P hidden connect 9 0 7 0;
#P connect 7 0 13 0;
#P window clipboard copycount 14;


Viewing 2 posts - 1 through 2 (of 2 total)