madskjeldgaard / portedplugins

A collection of plugins for the SuperCollider sound environment, all of which are ported / remixed from elsewhere
GNU General Public License v3.0
180 stars 13 forks source link

Rongs/Rongs examples broken? #41

Open defaultxr opened 6 months ago

defaultxr commented 6 months ago

Describe the bug Rongs does not seem to generate audio as I would expect.

To Reproduce Examples from Rongs' documentation:

(
Ndef(\c, {|pan=0.0, trigfreq=4|
    var trig = Dust2.kr(trigfreq);

    var sig = Rongs.ar(
        trig, 
        sustain: trig, 
        f0: [1.0,1.01] * TRand.kr(0.01,0.2, trig), 
        structure: TRand.kr(0.0,0.99,trig),
        brightness: TRand.kr(0.6,0.99,trig), 
        stretch: TRand.kr(0.1,0.99,trig), 
        damping: 0.7,
        //damping: TRand.kr(0.5,0.85, trig),
        accent: 0.99,
        loss: 0.1
    );

    Splay.ar(LeakDC.ar(sig), spread: 0.25, center: pan);
}).play;
)

(
SynthDef.new(\rongsinator, {|out, amp=0.25, pan=0, sustainTime=0.01, f0=0.05, structure=0.5, brightness=0.5, damping=0.75, accent=0.9, harmonicstretch=0.5, position=0.15, loss=0.15|
    var trig = Trig.kr(1, dur: sustainTime);

    var modeNum=2, cosFreq=0.025;
    var sig = Rongs.ar(
        trigger:trig, 
        sustain:trig, 
        f0:f0, 
        structure:structure, 
        brightness:brightness, 
        damping:damping, 
        accent:accent, 
        stretch:harmonicstretch, 
        position:position, 
        loss:loss, 
        modeNum:modeNum, 
        cosFreq:cosFreq
    );

    DetectSilence.ar(in: sig, amp: 0.0001, time: 0.1, doneAction: 2);
    sig = Pan2.ar(sig, pan);
    Out.ar(out, sig);
}).add;
)

// Trig it once
Synth(\rongsinator, [\damping, 0.5])

Neither of these seem to output any (or very quiet) audio for me. Even using Normalizer.ar doesn't give much in the way of any actual tones as I would expect. I can't get much out of it when playing around with the code either.

Expected behavior Audio along the lines of Mutable Instruments Rings or similar.

Additional context Using portedplugins v0.4.1 on SuperCollider 3.13.0 on Arch Linux.