scratcher/scrubber

Aug 1, 2007 at 6:44am

scratcher/scrubber

Here’re two failed attempts at making a patch that scratches through audio at the speed ones mouse, controller or vinyl record is moving. I am essentially trying to emulate scratching sounds with max. Any thoughts on my two failed attempts. Am I on the wrong path?

#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P message 332 492 23 196617 10.;
#P newex 281 396 43 196617 + 1000;
#P newex 277 360 27 196617 *;
#P newex 361 566 29 196617 sig~;
#P flonum 362 549 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 353 530 27 196617 / 1.;
#P newex 364 599 92 196617 groove~ thebuffer;
#P message 352 267 64 196617 resolution 1;
#P newex 356 461 55 196617 select 0 1;
#P number 381 434 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 473 408 14 196617 1;
#N counter;
#X flags 0 0;
#P newobj 381 411 66 196617 counter;
#P flonum 359 505 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 359 483 35 196617 timer;
#P button 353 387 15 0;
#P newex 353 359 27 196617 >;
#P user hslider 349 301 18 128 256 1 0 0;
#P newex 54 231 29 196617 sig~;
#P newex 400 151 37 196617 / 256;
#P message 145 60 64 196617 resolution 1;
#P button 236 124 15 0;
#P user ezdac~ 56 260 100 293 0;
#P message 106 179 43 196617 replace;
#P message 92 50 45 196617 mult $1;
#P newex 313 178 66 196617 mstosamps~;
#P newex 235 150 105 196617 info~ thebuffer;
#P user hslider 91 81 18 128 127 1024 0 0;
#P newex 106 198 122 196617 buffer~ thebuffer 30000;
#P newex 93 145 81 196617 peek~ thebuffer;
#P connect 14 0 28 0;
#P connect 14 0 17 0;
#P connect 16 0 23 1;
#P connect 23 0 24 0;
#P connect 28 0 23 0;
#P connect 27 0 22 0;
#P connect 26 0 27 0;
#P connect 10 0 26 1;
#P connect 12 0 26 0;
#P connect 12 0 13 0;
#P connect 12 0 13 1;
#P fasten 4 1 10 0 374 201 393 201 393 144 405 144;
#P connect 25 0 22 0;
#P connect 24 0 25 0;
#P connect 22 0 7 0;
#P connect 22 0 7 1;
#P connect 21 0 12 0;
#P connect 19 0 20 0;
#P connect 20 1 15 1;
#P connect 20 0 15 0;
#P connect 17 0 19 0;
#P fasten 18 0 17 4 452 465;
#P connect 15 0 16 0;
#P connect 13 0 14 0;
#P connect 11 0 7 0;
#P connect 11 0 7 1;
#P connect 0 0 11 0;
#P connect 2 0 0 0;
#P connect 9 0 2 0;
#P connect 8 0 3 0;
#P connect 6 0 1 0;
#P connect 5 0 2 0;
#P connect 3 6 4 0;
#P window clipboard copycount 29;

#33111
Aug 1, 2007 at 11:31am

try this:
go to the help for [sfplay~]
open [p new features]
open [p signal inputs]
scroll up and you should find [p auto_scratcher]

the output of this can be fed to groove~
using this is as a starting point you could give gestural control to
the user by replacing the bits that make it ‘auto’

hope that helps

sdf

On 01/08/07, Nicholas Esterer wrote:
>
> Here’re two failed attempts at making a patch that scratches through audio at the speed ones mouse, controller or vinyl record is moving. I am essentially trying to emulate scratching sounds with max. Any thoughts on my two failed attempts. Am I on the wrong path?
>
> #P window setfont “Sans Serif” 9.;
> #P window linecount 1;
> #P message 332 492 23 196617 10.;
> #P newex 281 396 43 196617 + 1000;
> #P newex 277 360 27 196617 *;
> #P newex 361 566 29 196617 sig~;
> #P flonum 362 549 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> #P newex 353 530 27 196617 / 1.;
> #P newex 364 599 92 196617 groove~ thebuffer;
> #P message 352 267 64 196617 resolution 1;
> #P newex 356 461 55 196617 select 0 1;
> #P number 381 434 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> #P message 473 408 14 196617 1;
> #N counter;
> #X flags 0 0;
> #P newobj 381 411 66 196617 counter;
> #P flonum 359 505 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> #P newex 359 483 35 196617 timer;
> #P button 353 387 15 0;
> #P newex 353 359 27 196617 >;
> #P user hslider 349 301 18 128 256 1 0 0;
> #P newex 54 231 29 196617 sig~;
> #P newex 400 151 37 196617 / 256;
> #P message 145 60 64 196617 resolution 1;
> #P button 236 124 15 0;
> #P user ezdac~ 56 260 100 293 0;
> #P message 106 179 43 196617 replace;
> #P message 92 50 45 196617 mult $1;
> #P newex 313 178 66 196617 mstosamps~;
> #P newex 235 150 105 196617 info~ thebuffer;
> #P user hslider 91 81 18 128 127 1024 0 0;
> #P newex 106 198 122 196617 buffer~ thebuffer 30000;
> #P newex 93 145 81 196617 peek~ thebuffer;
> #P connect 14 0 28 0;
> #P connect 14 0 17 0;
> #P connect 16 0 23 1;
> #P connect 23 0 24 0;
> #P connect 28 0 23 0;
> #P connect 27 0 22 0;
> #P connect 26 0 27 0;
> #P connect 10 0 26 1;
> #P connect 12 0 26 0;
> #P connect 12 0 13 0;
> #P connect 12 0 13 1;
> #P fasten 4 1 10 0 374 201 393 201 393 144 405 144;
> #P connect 25 0 22 0;
> #P connect 24 0 25 0;
> #P connect 22 0 7 0;
> #P connect 22 0 7 1;
> #P connect 21 0 12 0;
> #P connect 19 0 20 0;
> #P connect 20 1 15 1;
> #P connect 20 0 15 0;
> #P connect 17 0 19 0;
> #P fasten 18 0 17 4 452 465;
> #P connect 15 0 16 0;
> #P connect 13 0 14 0;
> #P connect 11 0 7 0;
> #P connect 11 0 7 1;
> #P connect 0 0 11 0;
> #P connect 2 0 0 0;
> #P connect 9 0 2 0;
> #P connect 8 0 3 0;
> #P connect 6 0 1 0;
> #P connect 5 0 2 0;
> #P connect 3 6 4 0;
> #P window clipboard copycount 29;
>
>

#109767
Aug 1, 2007 at 9:24pm

here’s a solution using [play~] :

max v2;
#N vpatcher 382 105 842 387;
#P origin 0 -30;
#P window setfont “Sans Serif” 9.;
#P hidden newex 447 119 38 9109513 pipe 50;
#P hidden newex 447 143 19 9109513 t 1;
#P hidden newex 447 87 66 9109513 loadmess 120;
#P window setfont “Sans Serif” 18.;
#P comment 319 24 100 9109522 dG_scratch;
#B frgb 21 56 9;
#P window setfont “Sans Serif” 9.;
#P comment 274 49 148 9109513 alex.thedigitalgarden@gmail.com;
#P user panel 225 19 198 48;
#X brgb 248 145 0;
#X frgb 0 0 0;
#X border 0;
#X rounded 0;
#X shadow 2;
#X done;
#P hidden newex 192 89 19 9109513 t b;
#P hidden newex 222 310 38 9109513 pipe 50;
#P hidden newex 118 60 65 9109513 r bufferlenght;
#P hidden newex 194 336 67 9109513 s bufferlenght;
#P hidden newex 297 317 65 9109513 r bufferlenght;
#P hidden newex 427 47 92 9109513 bgcolor 200 200 200;
#P comment 63 240 21 9109513 or;
#P comment 24 240 21 9109513 rec;
#P toggle 44 239 17 0;
#N vpatcher 447 225 767 537;
#P origin -17 0;
#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P newex 14 272 67 9109513 s bufferlenght;
#P window linecount 0;
#P newex 44 185 27 9109513 t f f;
#P newex 74 92 27 9109513 t 1 5;
#P newex 74 69 43 9109513 sel 1;
#P newex 201 161 27 9109513 t i i;
#N comlet connect to rec on/off;
#P outlet 61 253 15 0;
#P message 61 232 14 9109513 0;
#P window linecount 1;
#P newex 61 208 150 9109513 sel 5000;
#N comlet duree enregistrement;
#P inlet 201 48 15 0;
#P window linecount 0;
#P newex 201 125 35 9109513 * 1000;
#P number 201 69 35 9 1 120 3 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P message 218 186 37 9109513 size $1;
#P newex 218 208 73 9109513 buffer~ scratch;
#B color 5;
#P newex 14 46 70 9109513 t i i i;
#P newex 14 162 28 9109513 sel 0;
#P newex 14 208 40 9109513 float;
#P newex 44 162 49 9109513 clocker 1.;
#B color 5;
#P newex 118 126 70 9109513 adc~;
#P newex 118 162 73 9109513 record~ scratch;
#B color 5;
#P inlet 14 26 15 0;
#P connect 0 0 6 0;
#P connect 6 0 5 0;
#P connect 5 0 4 0;
#P connect 4 0 19 0;
#P connect 6 1 3 0;
#P connect 3 0 18 0;
#P connect 18 0 4 1;
#P connect 18 1 12 0;
#P connect 12 0 13 0;
#P connect 13 0 14 0;
#P connect 6 2 16 0;
#P connect 16 0 17 0;
#P connect 2 0 1 0;
#P fasten 2 1 1 0 183 152 123 152;
#P fasten 16 1 1 0 112 157 123 157;
#P fasten 17 0 1 0 79 157 123 157;
#P connect 11 0 9 0;
#P connect 9 0 10 0;
#P fasten 17 1 10 0 96 117 206 117;
#P connect 10 0 15 0;
#P connect 15 0 12 1;
#P connect 15 1 8 0;
#P connect 8 0 7 0;
#P pop;
#P hidden newobj 44 288 68 9109513 p rec;
#P toggle 393 207 31 0;
#P hidden newex 349 253 28 9109513 dac~;
#P hidden newex 280 253 44 9109513 zl slice 1;
#P hidden newex 192 111 59 9109513 loadmess 0.;
#P hidden message 8 112 33 9109513 line $1;
#P hidden message 280 367 36 9109513 $1 100;
#P hidden newex 280 340 27 9109513 * 1.;
#P hidden newex 144 288 105 9109513 info~ scratch;
#B color 5;
#P user meter~ 380 135 394 238 50 0 168 0 103 103 103 255 153 0 255 0 0 217 217 0 153 186 0 12 3 3 3 3;
#P user gain~ 349 135 32 81 158 0 1.071519 7.94321 10.;
#P hidden newex 44 110 98 9109513 loadmess set scratch;
#P user waveform~ 44 135 306 103 139 9;
#W mode none;
#W mouseoutput continuous;
#W unit ms;
#W grid 0.;
#W ticks 0;
#W labels 0;
#W vlabels 0;
#W vticks 0;
#W bpm 0.001 1.;
#W frgb 248 202 83;
#W brgb 248 145 0;
#W rgb2 255 255 255;
#W rgb3 0 0 0;
#W rgb4 0 0 0;
#W rgb5 187 204 160;
#W rgb6 0 0 0;
#W rgb7 75 75 75;
#P hidden newex 280 387 42 9109513 line~ 1.;
#P message 81 239 41 9109513 replace;
#P hidden newex 280 408 65 9109513 play~ scratch;
#B color 5;
#P hidden newex 81 262 73 9109513 buffer~ scratch;
#B color 5;
#P comment 393 194 33 9109513 on/off;
#P hidden fasten 10 0 12 0 285 362 4 362 4 110 13 110;
#P hidden fasten 12 0 5 0 13 132 49 132;
#P hidden connect 6 0 5 0;
#P hidden fasten 17 0 18 0 49 311 19 311 19 233 49 233;
#P hidden connect 18 0 17 0;
#P hidden connect 3 0 1 0;
#P hidden connect 24 0 5 1;
#P hidden connect 1 1 9 0;
#P hidden fasten 24 0 26 0 123 84 197 84;
#P hidden connect 26 0 13 0;
#P hidden connect 13 0 5 2;
#P hidden fasten 25 0 23 0 227 332 199 332;
#P hidden connect 9 6 25 0;
#P hidden fasten 13 0 5 3 197 132 271 132;
#P hidden connect 5 4 14 0;
#P hidden connect 14 0 10 0;
#P hidden connect 10 0 11 0;
#P hidden connect 11 0 4 0;
#P hidden connect 4 0 2 0;
#P hidden connect 22 0 10 1;
#P hidden fasten 30 0 7 0 452 112 354 112;
#P hidden fasten 2 0 7 0 285 430 442 430 442 125 354 125;
#P hidden fasten 16 0 15 0 398 241 354 241;
#P hidden connect 7 0 15 0;
#P hidden fasten 7 0 15 1 354 246 372 246;
#P hidden connect 7 0 8 0;
#P hidden fasten 31 0 16 0 452 169 398 169;
#P hidden connect 30 0 32 0;
#P hidden connect 32 0 31 0;
#P pop;

#109768

You must be logged in to reply to this topic.