On Wednesday 17 June 2009 15:07:14 nescivi wrote:
On Wednesday 17 June 2009 12:09:29 nescivi wrote:
On Wednesday 17 June 2009 03:36:27 Dan Stowell wrote:
What does it currently output?
Nothing. Just 0.
Loss of potential there :)
I started on a solution for this...
However, it doesn't seem to work yet...
but then I reverted back, and I don't even get anything written
with the
old version, and the standard helpfile example.
Something really strange is going on there!
Any clues what may be going on there?
sincerely,
Marije
I think I'm going insane:
------------------------------------
This works (most of the time at least):
s.boot; // start the server
(
// something to record
SynthDef("bubbles", {
var f, zout;
f = LFSaw.kr(0.4, 0, 24, LFSaw.kr([8,7.23], 0, 3, 80)).midicps; //
glissandofunction
zout = CombN.ar(SinOsc.ar(f, 0, 0.04), 0.2, 0.2, 4); // echoing sine
wave
Out.ar(0, zout);
}).send(s);
// this will record to the disk
SynthDef("help-Diskout2", {arg bufnum;
DiskOut.ar(bufnum, In.ar(0,2));
}).send(s);
// this will play it back
SynthDef("help-Diskin-2chan", { arg bufnum = 0;
Out.ar(0, DiskIn.ar(2, bufnum));
}).send(s);
)
Object Style:
// start something to record
x = Synth.new("bubbles");
// allocate a disk i/o buffer
b= Buffer.alloc(s, 65536, 2);
// create an output file for this buffer, leave it open
b.write("~/diskouttest.aiff".standardizePath, "aiff", "int16", 0, 0,
true);
// create the diskout node; making sure it comes after the source
d = Synth.tail(nil, "help-Diskout2", ["bufnum", b]);
// stop recording
s.queryAllNodes(true)
d.free;
// stop the bubbles
x.free;
// close the buffer and the soundfile
b.close;
// free the buffer
b.free;
------------------------------------
This doesn't:
s.boot; // start the server
(
// something to record
SynthDef("bubbles", {
var f, zout;
f = LFSaw.kr(0.4, 0, 24, LFSaw.kr([8,7.23], 0, 3, 80)).midicps; //
glissando
function
zout = CombN.ar(SinOsc.ar(f, 0, 0.04), 0.2, 0.2, 4); // echoing sine
wave
Out.ar(0, zout);
}).send(s);
// this will record to the disk
SynthDef("helpdiskout2", {arg bufnum;
DiskOut.ar(bufnum, In.ar(0,1));
}).send(s);
// this will play it back
SynthDef("help-Diskin-2chan", { arg bufnum = 0;
Out.ar(0, DiskIn.ar(2, bufnum));
}).send(s);
)
Object Style:
// start something to record
x = Synth.new("bubbles");
// allocate a disk i/o buffer
b= Buffer.alloc(s, 65536, 2);
// create an output file for this buffer, leave it open
b.write("~/diskouttest2.aiff".standardizePath, "aiff", "int16", 0,
0, true);
// create the diskout node; making sure it comes after the source
d = Synth.tail(nil, "helpdiskout2", ["bufnum", b.bufnum]);
// stop recording
s.queryAllNodes( true )
d.free;
// stop the bubbles
x.free;
// close the buffer and the soundfile
b.close;
// free the buffer
b.free;
_______________________________________________
sc-users mailing list
info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-users/
search: https://listarc.bham.ac.uk/lists/sc-users/search/