Differences between revisions 1 and 4 (spanning 3 versions)
Revision 1 as of 2006-11-25 16:32:11
Size: 991
Editor: 201-43-237-52
Comment:
Revision 4 as of 2006-11-25 16:54:10
Size: 1139
Editor: 201-43-237-52
Comment:
Deletions are marked like this. Additions are marked like this.
Line 4: Line 4:
Available examples not in manual (please add): #

#

= Title 1 =
Available examples not in manual (please add):
Line 8: Line 12:
#and alternating L-R output [[BR]]#and alternating L-R output
Line 11: Line 15:
import time [[BR]]import time
Line 14: Line 18:
osc = sndobj.Oscili(tab, 440, 10000)
noise = sndobj.Randh(100000, 10000)
[[BR]]osc = sndobj.Oscili(tab, 440, 10000)
[[BR]]noise = sndobj.Randh(100000, 10000)
Line 18: Line 22:
y=2 [[BR]]y=2
Line 21: Line 25:
outp.SetOutput(x, osc)
outp.SetOutput(y, noise)
[[BR]]outp.SetOutput(x, osc)
[[BR]]outp.SetOutput(y, noise)
Line 25: Line 29:
osc.SetFreq(440,mod) [[BR]]osc.SetFreq(440,mod)
Line 28: Line 32:
mod.SetFreq(2, mod2) [[BR]]mod.SetFreq(2, mod2)
Line 31: Line 35:
mod3 = sndobj.Oscili(tab, q, 1000)
noise.SetFreq(1000, mod3)
[[BR]]mod3 = sndobj.Oscili(tab, q, 1000)
[[BR]]noise.SetFreq(1000, mod3)
Line 35: Line 39:
thread.AddObj(mod)
thread.AddObj(mod2)
thread.AddObj(mod3)
thread.AddObj(osc)
thread.AddObj(noise)
thread.AddObj(outp, sndobj.SNDIO_OUT)
[[BR]]thread.AddObj(mod)
[[BR]]thread.AddObj(mod2)
[[BR]]thread.AddObj(mod3)
[[BR]]thread.AddObj(osc)
[[BR]]thread.AddObj(noise)
[[BR]]thread.AddObj(outp, sndobj.SNDIO_OUT)
Line 48: Line 52:
        y=1         [[BR]]y=1
Line 51: Line 55:
        y=2         [[BR]]y=2
Line 53: Line 57:
    outp.SetOutput(y, noise)     [[BR]]outp.SetOutput(y, noise)
Line 55: Line 59:
    n +=1     [[BR]]n +=1

homepage: http://sndobj.sourceforge.net/#python

#

#

= Title 1 = Available examples not in manual (please add):

#simple synth with band limited noise, oscilators, BR#and alternating L-R output

import sndobj BRimport time

tab = sndobj.HarmTable() BRosc = sndobj.Oscili(tab, 440, 10000) BRnoise = sndobj.Randh(100000, 10000)

x=1 BRy=2

outp = sndobj.SndRTIO(2) BRoutp.SetOutput(x, osc) BRoutp.SetOutput(y, noise)

mod = sndobj.Oscili(tab, 2, 560) BRosc.SetFreq(440,mod)

mod2=sndobj.Oscili(tab, 4, 50) BRmod.SetFreq(2, mod2)

q=2 BRmod3 = sndobj.Oscili(tab, q, 1000) BRnoise.SetFreq(1000, mod3)

thread = sndobj.SndThread() BRthread.AddObj(mod) BRthread.AddObj(mod2) BRthread.AddObj(mod3) BRthread.AddObj(osc) BRthread.AddObj(noise) BRthread.AddObj(outp, sndobj.SNDIO_OUT)

thread.ProcOn()

n=0 while n < 8:

thread.ProcOff()

PySndObj (last edited 2008-11-15 14:00:59 by localhost)

Unable to edit the page? See the FrontPage for instructions.