<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'>cm clm s7<br><br>Hi,<br>I'm getting confused over :channels 2 for with-sound and stereo output.&nbsp; I was thinking to get stereo output I just needed to add the :channels 2 argument to with-sound if out-any is used in the instrument.&nbsp; <br><br>Seems like I can only get one channel (one side) with :channels 2.&nbsp; If I use :channels 1 I get dual mono (two sides).<br><br>If I try Fernando's move-osc with locsig the sound pans and I can see two channels using Snd as editor.&nbsp; But for examp2 below, I just get one channel.<br><br>I'm wondering where I might be getting confused.<br><br>Thanks,<br>Jim<br><br><br>&nbsp;(definstrument (move-osc beg dur freq amp <br>&nbsp;(degree 0.0) (dist 1.0) (reverb 0.03))<br>&nbsp; (let* ((start (seconds-&gt;samples beg))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (end (seconds-&gt;samples (+ beg dur))) <br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (car (make-oscil :frequency freq))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (loc (make-locsig :degree degree :distance dist :channels 2))<br>&nbsp;&nbsp;&nbsp; &nbsp;(pan-env (make-env '(0 0 1 90) :duration dur))) <br>&nbsp;&nbsp;&nbsp; <br>&nbsp;&nbsp;&nbsp;&nbsp; (do ((i start (+ i 1)))<br>&nbsp;&nbsp;&nbsp;&nbsp; ((= i end))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (let ((ut (* amp (oscil car))))<br>&nbsp;&nbsp;&nbsp; &nbsp;(move-locsig loc (env pan-env) dist)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (locsig loc i ut)))))<br><br><br>(with-sound (:output "test.wav" :srate 48000 :channels 2<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :data-format mus-lshort<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :header-type&nbsp; mus-riff) <br>&nbsp;&nbsp; (move-osc&nbsp;&nbsp;&nbsp; 0&nbsp;&nbsp;&nbsp; 3&nbsp;&nbsp;&nbsp; 220.0&nbsp;&nbsp;&nbsp; 0.75&nbsp; 0 1.0 0.3))<br><br>;;-------------------------------------------------<br><br>(definstrument (examp2 beg dur frequency amplitude)<br>&nbsp; (let* ((start (seconds-&gt;samples beg))<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (end (seconds-&gt;samples (+ beg dur))) <br>&nbsp;&nbsp;&nbsp; &nbsp;(sine-wave (make-oscil :frequency frequency)))<br>&nbsp;&nbsp;&nbsp;&nbsp; (do ((i start (+ i 1)))<br>&nbsp;&nbsp;&nbsp;&nbsp; ((= i end))<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp; (outa i (* amplitude (oscil sine-wave))))))<br><br>(with-sound (:output "test2.wav" :srate 48000 :channels 2<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :data-format mus-lshort<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; :header-type&nbsp; mus-riff) <br>&nbsp;&nbsp; (examp2&nbsp;&nbsp;&nbsp; 0&nbsp;&nbsp;&nbsp; 3&nbsp;&nbsp;&nbsp; 220.0&nbsp;&nbsp;&nbsp; 0.75))<br><br>                                               </div></body>
</html>