Forums > MaxMSP

problem with mute~ pass~ output


MG
May 15, 2006 | 9:52 pm

i have a few effects subpatches running on a signal and i am trying to set it so when they are not in use, the dsp will shut them off to save some CPU.

sort like this ..

signal—->[p pitch]—>[p delay]—>[*~]–>[dac]

and then i have mute~ connected to the sub patches with the effects inside them (pitch is pfft gizmo object, and delay is some tapin tapout stuff).

the problem is, when i toggle the mute object on, instead of just turning off that effect and sending an uneffected signal through, it just kills the signal right there. i tried removing the pass~ object, but that gave major problems with amplitude.

it seems like i am missing something obvious here, can anyone shed some light on me?

another post suggested using poly~ objects, but i had the same problem with that method.

what am i doing wrong?!?!


May 15, 2006 | 10:00 pm

Mute does kill the signal, that’s just the way it works. If you need the clean signal use a gate~ to route the signal past the muted subpatcher.

best,



MG
May 15, 2006 | 10:03 pm

okay great,

thank you for the quick reply!!


May 16, 2006 | 12:06 am


May 16, 2006 | 2:11 am

I think you want to do something like this.

-Jonathan

max v2;
#N vpatcher 400 852 845 1129;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P hidden newex 90 120 45 196617 loadbang;
#P hidden newex 96 191 27 196617 *~ 1;
#P hidden newex 134 162 38 196617 begin~;
#P hidden newex 84 218 61 196617 selector~ 2;
#P window setfont "Sans Serif" 12.;
#P message 108 45 25 196620 Off;
#B color 6;
#P window setfont "Sans Serif" 9.;
#P hidden message 10 148 14 196617 2;
#P hidden message 74 148 14 196617 1;
#P window linecount 2;
#N vpatcher 338 107 1174 841;
#P origin 37 0;
#P window setfont "Sans Serif" 9.;
#P hidden newex 455 86 45 196617 loadbang;
#P window setfont "Lucida Grande" 14.;
#P hidden message 455 111 102 14 ; max preempt 1;
#B color 1;
#P comment 556 111 233 14 System Requirements: MAX Scheduler in
Overdrive must be On (in patchers too);
#B color 1;
#P window setfont "Sans Serif" 9.;
#P number 152 467 31 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P hidden comment 417 348 123 196617 initialize EQ status;
#B color 1;
#P message 359 341 35 196617 Off On;
#B color 1;
#P button 272 371 15 0;
#P button 70 375 15 0;
#N comlet symbol: state 1 (+ color setting);
#P outlet 405 530 15 0;
#P newex 438 483 54 196617 prepend set;
#P newex 359 483 54 196617 prepend set;
#P message 438 451 19 196617 On;
#P message 359 453 22 196617 Off;
#P message 516 470 41 196617 color 1;
#B color 1;
#P message 313 469 41 196617 color 6;
#B color 1;
#N comlet message: change button state;
#P inlet 165 45 15 0;
#P hidden comment 237 369 31 196617 set to On;
#B color 1;
#P hidden comment 88 375 32 196617 set to Off;
#B color 1;
#P newex 219 311 44 196617 loadbang;
#P message 152 384 32 196617 set 0;
#P toggle 165 124 15 0;
#P button 165 84 15 0;
#P hidden comment 160 325 33 196617 Off;
#B color 1;
#P hidden comment 125 325 33 196617 On;
#B color 1;
#P button 165 263 15 0;
#P button 136 263 15 0;
#N comlet On;
#P outlet 165 303 15 0;
#N comlet Off;
#P outlet 136 303 15 0;
#P newex 361 160 124 196617 if $i1 == 0 then 1 else out2 0;
#P user gswitch2 136 208 39 32 1 0;
#P newex 438 406 54 196617 prepend set;
#P newex 359 408 54 196617 prepend set;
#P newex 359 376 89 196617 unpack x x;
#P comment 556 54 100 196617 Anything not in red is unmodified code
contributed by Sigthor Hrafnsson.;
#P comment 48 84 114 196617 this bang gets triggered by turning on the EQ;
#P comment 52 208 81 196617 this graphic gate controls what the On/Off
button does;
#P comment 433 531 100 196617 this outlet sets the state and color of
the button;
#P fasten 8 1 29 0 480 280 75 280;
#P fasten 8 0 7 0 366 195 141 195;
#P fasten 8 1 7 0 480 201 141 201;
#P connect 7 0 11 0;
#P connect 11 0 9 0;
#P lcolor 2;
#P fasten 18 0 17 0 224 363 157 363;
#P connect 17 0 33 0;
#P connect 21 0 15 0;
#P fasten 17 0 16 0 157 407 45 407 45 122 170 122;
#P fasten 15 0 16 0 170 119 170 119;
#P connect 16 0 7 1;
#P connect 7 1 12 0;
#P connect 12 0 10 0;
#P lcolor 2;
#P fasten 8 0 30 0 366 280 277 280;
#P fasten 30 0 22 0 277 421 318 421;
#P fasten 18 0 31 0 224 337 364 337;
#P lcolor 2;
#P connect 31 0 4 0;
#P connect 4 0 5 0;
#P connect 5 0 24 0;
#P fasten 30 0 24 0 277 448 364 448;
#P connect 24 0 26 0;
#P fasten 16 0 8 0 170 149 366 149;
#P fasten 26 0 28 0 364 522 410 522;
#P fasten 22 0 28 0 318 522 410 522;
#P fasten 23 0 28 0 521 522 410 522;
#P fasten 27 0 28 0 443 522 410 522;
#P connect 4 1 6 0;
#P fasten 29 0 25 0 75 442 443 442;
#P connect 6 0 25 0;
#P connect 25 0 27 0;
#P hidden connect 36 0 35 0;
#P fasten 29 0 23 0 75 435 521 435;
#P pop;
#P hidden newobj 10 76 138 196617 patcher TwoStateButtonOutside;
#N comlet Signal Input;
#P hidden inlet 109 162 15 0;
#P window linecount 1;
#P hidden message 174 30 52 196617 nfilters 4;
#P window setfont Helvetica 9.;
#P user filtergraph~ 174 51 256 128 21 9 20. 20000. 0.0625 16. 0 1 1 0 0
1 1;
#X frgb 170 170 170;
#X brgb 209 209 209;
#X rgb2 0 0 0;
#X rgb3 130 130 130;
#X rgb4 0 0 0;
#X rgb5 76 108 172;
#X rgb6 210 74 54;
#X rgb7 255 22 22;
#X linmarkers 5512.5 11025. 16537.5;
#X logmarkers 10. 100. 1000. 10000.;
#X nfilters 4;
#X setfilter 3 5 1 0 0 1156.954102 1.048069 0.182606 0. 0. 0. 0. 0. 0.;
#X setfilter 2 5 1 0 0 735.11 0.0001 1.332655 0. 0. 0. 0. 0. 0.;
#X setfilter 1 5 1 0 0 3359.236084 6.178762 2.82754 0. 0. 0. 0. 0. 0.;
#X setfilter 0 5 1 0 0 10009.350586 2.095047 1.966332 0. 0. 0. 0. 0. 0.;
#X done;
#P window setfont "Sans Serif" 9.;
#P hidden newex 134 190 50 196617 cascade~;
#N comlet Signal Output;
#P hidden outlet 84 246 15 0;
#P hidden fasten 8 0 5 0 113 65 15 65;
#P hidden connect 5 0 7 0;
#P hidden connect 12 0 6 0;
#P hidden connect 5 1 6 0;
#P hidden fasten 7 0 9 0 15 174 89 174;
#P hidden fasten 6 0 9 0 79 174 89 174;
#P hidden connect 9 0 0 0;
#P hidden fasten 4 0 11 0 114 184 101 184;
#P hidden fasten 5 2 8 0 140 108 158 108 158 24 113 24;
#P hidden fasten 11 0 9 1 101 213 114 213;
#P hidden fasten 4 0 1 0 114 183 139 183;
#P hidden connect 10 0 1 0;
#P hidden connect 1 0 9 2;
#P hidden connect 3 0 2 0;
#P hidden connect 2 0 1 1;
#P pop;


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