<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Hi,<br>I'm getting myself confused about the following info below from the manual about outa and *reverb*. If I'm understanding correctly then, *reverb* is not a reverberator and you still have to supply one, such as jc-rev, which I think I did below using with-sound.<br><br>But I'm stuck trying to figure out how to use a reverberator with a scheme process instead of with-sound. I know I can include the the reverb-amount etc. on the "send" line in the process, but I can't seem to figure out how to to include the jc-reverberator with the process or define.<br><br>Do I include the reverberator in the definstrument perhaps for calling it with a process? I know using reverb from a scheme process is much easier if I use locsig instead of outa, but I was hoping I might understand if will work or not.<br><br>Thank You,<br>Jim<br>------<br>*reverb*
<br>The reverb instrument has to send to the *reverb* output stream an <br>appropriately scaled version of its main output, something like:
<br>
<br>(outa i (* sample reverb-amount) *reverb*)
<br>
<br>What clm does is, after with-sound processes the whole "note list" that
<br>is its body, it runs the reverb instrument that you supply over the
<br>reverb soundfile that it generated as part of running the body and then
<br>merges the output of that instrument run into the main soundfile generated.<br>--------<br>(if (not (provided? 'jcrev.scm))
<br> (load "jcrev.scm"))<br><br>(definstrument (myexamp start-time duration frequency amplitude sampling-rate<br> (reverb-amount 0.01))
<br> (let* ((beg (floor (* start-time sampling-rate)))
<br> (end (+ beg (floor (* duration sampling-rate))))
<br> (sine-wave (make-oscil :frequency frequency)))
<br> (do ((i beg (+ i 1)))
<br> ((= i end)) <br>(outa i (* (* (* amplitude (oscil sine-wave))) reverb-amount) *reverb*)<br>(outb i (* (* (* amplitude (oscil sine-wave))) reverb-amount) *reverb*)
)))
<br><br>(with-sound (:output "test.wav" :srate 48000 :channels 2
<br> :data-format mus-lshort
<br> :header-type mus-riff<br> :reverb jc-reverb) <br>(myexamp 0 1 440.0 0.5 48000 :reverb-amount 0.15))<br><br>;---------------------------------<br>;using a process<br>(define (call_myexamp n r d flb fub amp sr)
<br>(process
<br> for freq = (between flb fub)
<br> repeat n do
<br> (send "myexamp" (elapsed) d freq amp sr )
<br> (wait r) ))
<br> <br>(sprout(call_myexamp 40 .15 .10 500 2000 0.5 48000) "mytest.wav")<br><br>                                            </div></body>
</html>