Re: SynthDefs, synthDefDir

[email protected] Sun, 30 May 2021 11:53:40 +0800
Newsgroups gmane.comp.audio.supercollider.user
Message-ID <CAFniQ7Vb-FJKkvf9i7mgHJ=_LA7agt5ti+oUNzane6UcuZHKHQ@mail.gmail.com>
Actually the example has a mistake (according to a comment in the
code): "// don't use *read or *readFile to read into a SynthDescLib.
Use SynthDescLib:read or SynthDescLib:readStream instead" -- so it
should be:

d = SynthDef(\test, { |freq = 440|
    Out.ar(0, SinOsc.ar(freq, 0, 0.1).dup)
});

e = d.asBytes;

f = SynthDescLib.global.readStream(CollStream(e));

SynthDescLib.at(\test).controls;

But again, generally there's no reason to do that by hand.

hjh

_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: http://www.listarc.bham.ac.uk/marchives/sc-users/
search: http://www.listarc.bham.ac.uk/lists/sc-users/search/