Re: [Sndobj-devel] SndBuffer examples
Status: Abandoned
Brought to you by:
veplaini
From: Victor L. <Vic...@nu...> - 2007-02-06 14:44:59
|
SndBuffer is fixed now in CVS. Here's an example that runs an oscillator in one thread and outputs it in another. import sndobj import time # sndbuffer (size = 4 x vectorsize) buf = sndobj.SndBuffer(1,1024) # wavetable harm = sndobj.HarmTable(10000,1,1) # thread 1 # outputs to buf t1 = sndobj.SndThread() osc = sndobj.Oscili(harm, 440, 10000) buf.SetOutput(1, osc) t1.AddObj(osc) t1.AddObj(buf, sndobj.SNDIO_OUT) # thread 2 # input from buf # output to outp t2 = sndobj.SndThread() sound = sndobj.SndIn(buf, 1) outp = sndobj.SndRTIO(sound) t2.AddObj(buf, sndobj.SNDIO_IN) t2.AddObj(sound) t2.AddObj(outp, sndobj.SNDIO_OUT) t1.ProcOn() t2.ProcOn() time.sleep(10) t2.ProcOff() t1.ProcOff() Victor At 12:06 06/02/2007, you wrote: >It looks like some of the latest changes to the lib might have broken >SndBuffer. I am looking at fixing it now. I will post an example when >I am done > >At 03:26 06/02/2007, you wrote: > >Does anyone have any code employing the SndBuffer Class that they'd > >care to post to give as an example? I'm interested in anything, but > >am specifically looking for examples where the Buffer passes data > >between different threads. > > > >Thanks, > >Craig > > > >------------------------------------------------------------------------- > >Using Tomcat but need to do more? Need to support web services, security? > >Get stuff done quickly with pre-integrated technology to make your job > easier. > >Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > >http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > >_______________________________________________ > >Sndobj-devel mailing list > >Snd...@li... > >https://lists.sourceforge.net/lists/listinfo/sndobj-devel > >Victor Lazzarini >Music Technology Laboratory >Music Department >National University of Ireland, Maynooth > > >------------------------------------------------------------------------- >Using Tomcat but need to do more? Need to support web services, security? >Get stuff done quickly with pre-integrated technology to make your job easier. >Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo >http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 >_______________________________________________ >Sndobj-devel mailing list >Snd...@li... >https://lists.sourceforge.net/lists/listinfo/sndobj-devel Victor Lazzarini Music Technology Laboratory Music Department National University of Ireland, Maynooth |