From: owner-sc-users-digest@lists.io.com (sc-users-digest) To: sc-users-digest@lists.io.com Subject: sc-users-digest V1 #47 Reply-To: sc-users Sender: owner-sc-users-digest@lists.io.com Errors-To: owner-sc-users-digest@lists.io.com Precedence: bulk sc-users-digest Sunday, June 27 1999 Volume 01 : Number 047 ---------------------------------------------------------------------- Date: Thu, 24 Jun 1999 23:17:33 -0700 From: garrett james <---@---.---> Subject: 3 band eq implementation Hey folks, James Mc, this is Garrett P. James Jedi knight and friend of Captain Solo. I mean, I have paid, my old email address was dsp@music.dartmouth.edu, garrett_james@yahoo.com. I have this project of crazy spawn, cycle, supercollider sequencing functionality, and now I need a little help brainstorming how using SuperCollider's tools I can implement a (cheap) 3-band eq to control with my Peavy 1600x. I have a couple ideas, they just seem like overkill work... I would basically like to use 9 sliders of the peavy to control the 3 different streams of output for on the fly adjustment of the mix. (I really need help with concepts using the available tools to make the eq, i can write the code ;-) Thanks so much, - -Garrett ps: James, could you delete my old addy from the mailing list, I cannot log in anymore to send an unsub mail from my old account. Thankyou. ------------------------------ Date: Fri, 25 Jun 1999 02:30:54 -0700 From: garrett james <---@---.---> Subject: choices based on midi values Hi, I know the following is not right, but what is a method to imitate this type of functionality? I have many uses for different Midi slider messages that can be interpreted... I guess what Im asking, is how can one consistantly poll the current value of a *.kr type function and act on that value, use a little logic... if (MIDIController.kr(16,23,0,2).value < 1.0, {MIDIController.kr(16,23,0,1)},{1.0}); (This example/idea would ideally control would go up at 1:1, then completely flat not increasing at all for the second half of the slider's movement...) Thankyou, - -Garrett ------------------------------ Date: Fri, 25 Jun 1999 12:07:17 -0400 (EDT) From: David Crandall <---@---.---> Subject: Turbosynth time-stretcher Does anyone know the operating principle of the Time Stretcher object in Turbosynth? The thing that struck me about it is that with extreme time stretch, the user can enter a fundamental frequency and the stretched signal then seems to be passing through an overtone series for that fundamental (maybe not explaining this clearly). I'd like to make a version that can be controlled, fundamental modulated, etc., in real time (with the signal looping). Related question: would this be more easily done in MSP (which I don't have yet)? dc ------------------------------ Date: Fri, 25 Jun 1999 09:41:40 -0700 From: Mark Polishook <---@---.---> Subject: re: Routine James and Mark, Thanks for the discussion/clarification of Routine! mp ------------------------------ Date: Sat, 26 Jun 1999 10:42:00 -0700 From: garrett james <---@---.---> Subject: Re: choices based on midi values well, i found doing a sqrt(MIDIController.kr(16,23,0,2)) gives me nearly exactly the behavior i need (although i still wonder whether there is a member function for kr's that you can poll the current value and use it for something below...ie: the non-ugen world...) that aside, if anyone can help me implement a three band eq with the tools available, my brain is jammed for a way to do this optimally. Thanks! - -Garrett >Hi, > >I know the following is not right, but what is a method to imitate this >type of functionality? I have many uses for different Midi slider messages >that can be interpreted... > >I guess what Im asking, is how can one consistantly poll the current value >of a *.kr type function and act on that value, use a little logic... > >if (MIDIController.kr(16,23,0,2).value < 1.0, >{MIDIController.kr(16,23,0,1)},{1.0}); > >(This example/idea would ideally control would go up at 1:1, then >completely flat not increasing at all for the second half of the slider's >movement...) > >Thankyou, >-Garrett ------------------------------ Date: Sat, 26 Jun 1999 17:57:17 -0400 From: "crucial" <---@---.---> Subject: PrndGated James, thanks for the help on FilterPatterns. .collect and .reject turn out to be very useful ways to work on patterns. In working with Environments, it seems that one would want the Environment to contain all kinds of functions, values and things like Orchestras that it isn't worth shlepping around inside the protoEvent. But when the ugenFunction.valueEnvir happens, it is inside the event, and the currentEnvironment is that of the Event. Didn't you previously have a more complicated system that kept multiple environments 'active' ? I do : event.put('envir',currentEnvironment) then within the event the mothership of paramaters can be accessed by ~envir.at(\whatever) There is a better way ? thankx. Thinking compositionally, I wanted to be able to influence the rate of change, sit on an area when it sounds good, and move on when it needs to move on. I built this which turns out to be very useful. PrndGate : ListPattern { // gate, when valued, determines whether to choose a new value or to keep sending // the last one var <>gate; *new { arg list, gate, repeats=1; ^super.new.list_(list).repeats_(repeats).gate_(gate) } asStream { ^Routine.new({arg inval; var item; // must start with something item= list @ list.size.rand; repeats.value.do({arg i; if(gate.value,{ item = list @ list.size.rand; }); inval = item.embedInStream(inval) }) }) } } example: (tho not too pretty) var mx; Pbind(\note,PrndGate([12,14,16,18,20],{ mx.poll>0.5},inf), \tempo, 10 ).play(Event.protoEvent,1,{mx=MouseX.kr}) Also of possible interest to y'all : This plays the list as does Pseq. On each event, if gate evaluates to true, the function filter is valued, passed the inval, and the result placed at that point in the list. PseqLooper : Pseq { var <>gate,<>filter; *new { arg list, filter, gate,repeats=1, offset=0; ^super.new(list, repeats).offset_(offset).filter_(filter).gate_(gate) } asStream { ^Routine.new({ arg inval; var item, offsetValue; offsetValue = offset.value; repeats.value.do({ arg j; list.size.do({ arg i; var iv; iv=i + offsetValue; item = list @@ (iv); if(gate.value(item,iv),{ item = filter.value(item,iv); list.wrapPut(iv,item); }); inval = item.embedInStream(inval); }); }); }); } } examples : (much prettier) ( var mx; Pbind(\degree,PseqLooper([0,1,2,3,4],{ 12.rand},{mx.poll.rand > 0.5},inf), \tempo, 12 ).play(Event.protoEvent,1,{mx=MouseX.kr}) ) ( var mx; Pbind(\degree,PseqLooper([0,1,2,3,4],{arg item,i; item + 2.bilinrand},{mx.poll.rand > 0.5},inf), \tempo, 12 ).play(Event.protoEvent,1,{mx=MouseX.kr}) ) (var mx; Pbind(\note,PseqLooper([0,1,2,3,4],{arg item,i; item + 2.bilinrand},{mx.poll.rand > 0.5},inf), \tempo, 12, \dur,PseqLooper([1,2,3,4],{arg item,i; [0.25,0.5,1].choose},{mx.poll.rand > 0.5},inf) ).play(Event.protoEvent,1,{mx=MouseX.kr}) ) __________________________________________ :\\_______ http://crucial-systems.com __________________________________________ :\\_______ ------------------------------ Date: Sat, 26 Jun 1999 17:57:29 -0400 From: "crucial" <---@---.---> Subject: the gc crash There's this one that happens once every week or so : gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C gc->numGrey 1, but none found set 0 black list obj color wrong 127 (2, 1, 0) 32F632C etc. etc. until it locks up or I can manage to quit quickly. Restart SC and its fine, no need to restart the mac. not really related to anything, it has happened occasionally for several versions. __________________________________________ :\\_______ http://crucial-systems.com __________________________________________ :\\_______ ------------------------------ Date: Sat, 26 Jun 1999 17:59:18 -0400 From: "crucial" <---@---.---> Subject: subclassing Orchestra error I tried to subclass Orchestra but got Cannot find superclass 'Orchestra' for class 'Orc' I could subclass : Object, Collection I could not subclass : Set, IdentitySet, Orchestra, Dictionary, IdentityDictionary Orchestra and Instruments are working just fine actually. __________________________________________ :\\_______ http://crucial-systems.com __________________________________________ :\\_______ ------------------------------ Date: Sat, 26 Jun 1999 18:03:02 -0400 From: "crucial" <---@---.---> Subject: Dictionary.choose ? James Would it be possible to create a choose method for Dictionary ? I mean I can add it myself, but IdentityDictionary is a primitive, and it might be much better (at high speeds) to have it implemented there. Just a thought. thank you! __________________________________________ :\\_______ http://crucial-systems.com __________________________________________ :\\_______ ------------------------------ Date: Sat, 26 Jun 1999 18:21:28 -0400 From: "crucial" <---@---.---> Subject: Re: choices based on midi values >well, i found doing a sqrt(MIDIController.kr(16,23,0,2)) gives me nearly >exactly the behavior i need > >(although i still wonder whether there is a member function for kr's that >you can poll the current value and use it for something below...ie: the >non-ugen world...) The solution entirely depends on how its being used. the midi controller is .kr so its continuous, if you do a math operation to it, it creates a bin-op ugen which continuously outputs the result of the math operation. that in turn can be attached to anything. so there is no need to keep asking it questions. if the value in question is only used at individual events (like spawn happenings) then you can at that particular point whatever.kr.poll now you have a fixed value, and you can do any math to it you like. so i think what you want to do is var mc; mc=MIDIController.kr(16,23,0,2); then later on (inside your loop or whatever) go mc.poll and do what thou willst > >that aside, if anyone can help me implement a three band eq with the tools >available, my brain is jammed for a way to do this optimally. > >Thanks! >-Garrett > >>Hi, >> >>I know the following is not right, but what is a method to imitate this >>type of functionality? I have many uses for different Midi slider messages >>that can be interpreted... >> >>I guess what Im asking, is how can one consistantly poll the current value >>of a *.kr type function and act on that value, use a little logic... >> >>if (MIDIController.kr(16,23,0,2).value < 1.0, >>{MIDIController.kr(16,23,0,1)},{1.0}); >> >>(This example/idea would ideally control would go up at 1:1, then >>completely flat not increasing at all for the second half of the slider's >>movement...) >> >>Thankyou, >>-Garrett > > > > __________________________________________ :\\_______ http://crucial-systems.com __________________________________________ :\\_______ ------------------------------ Date: Sun, 27 Jun 1999 21:36:31 -0600 From: James McCartney <---@---.---> Subject: ouch! Saturday I wedged my finger between a water ski rope handle and a ski which sliced through my left middle fingernail to the bone, causing an open fracture of the finger tip into three pieces. Received 4 stitches. It is hard to type with 1.5 hands. I now look like I am flipping the finger due to the splint.. So I may be a bit slow in answering questions for a while.. --- james mccartney james@audiosynth.com http://www.audiosynth.com If you have a PowerMac check out SuperCollider2, a real time synth program: ------------------------------ End of sc-users-digest V1 #47 *****************************