<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Hi,</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
I'm having a problem passing a changing parameter(by an LFO in another function) to a function i'm sporking . Maybe this isn't possible :-( but i'd like your opinion) This is part of my script. Let me tell you this: When i give float
<b><span style="color: rgb(179, 106, 226);">Cfreq</span> </b>an initial value of 0.3<span style="color: rgb(81, 167, 249);">&nbsp; LFO</span> does change gain of SinOsc c. If i don't give it an initial value and have
<i><span style="color: rgb(12, 136, 42);">LFOtochangeCfreq</span> </i>change it&nbsp; -&gt; no sound.</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<div><br>
</div>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<span>&nbsp;SinOsc m =&gt; SinOsc c =&gt; Pan2 p =&gt; dac;<br>
</span>
<div>2 =&gt; c.sync;<br>
</div>
<div>float <span style="color: rgb(179, 106, 226);"><b>Cfreq</b></span>;&nbsp; <span style="background-color: rgb(204, 204, 204);">
&nbsp;//if i replace this line by: .3 =&gt; float Cfreq;&nbsp;</span><br>
</div>
<div><br>
</div>
<div>spork ~ <span style="color: rgb(12, 136, 42);"><i>LFOtochangeCfreq</i></span>(.1);<br>
</div>
<div>spork ~ <span style="color: rgb(81, 167, 249);">LFO</span>(<span style="color: rgb(179, 106, 226);"><b>Cfreq</b></span>);<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>fun void <span style="color: rgb(12, 136, 42);"><i>LFOtochangeCfreq</i></span>(float variation) {<br>
</div>
<div>&nbsp; &nbsp; SinOsc lfo =&gt; blackhole;<br>
</div>
<div>&nbsp; &nbsp; variation =&gt; lfo.freq;<br>
</div>
<div>&nbsp; &nbsp; while( true )<br>
</div>
<div>&nbsp; &nbsp; { <br>
</div>
<div>&nbsp; &nbsp; 1000::samp =&gt; now;<br>
</div>
<div>&nbsp; &nbsp; &lt;&lt;&lt;lfo.last() =&gt; <span style="color: rgb(179, 106, 226);"><b>Cfreq</b></span>&gt;&gt;&gt;;<br>
</div>
<div>&nbsp; &nbsp; }<br>
</div>
<div>&nbsp;}</div>
<div><br>
</div>
<div>fun void <span style="color: rgb(81, 167, 249);">LFO</span>(float LFOfreq) {<br>
</div>
<div>&nbsp; &nbsp; SinOsc lfo =&gt; blackhole;<br>
</div>
<div>&nbsp; &nbsp; LFOfreq =&gt; lfo.freq;<br>
</div>
<div>&nbsp; &nbsp; while( true )<br>
</div>
<div>&nbsp; &nbsp; { <br>
</div>
<div>&nbsp; &nbsp; 1::samp =&gt; now;<br>
</div>
<div>&nbsp; &nbsp; lfo.last() =&gt; c.gain ;<br>
</div>
<div>&nbsp; &nbsp; }<br>
</div>
<div>}<br>
</div>
<div><br>
</div>
<span>while (1) 10::ms=&gt; now;</span><br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
</body>
</html>