<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Windows-1252">
<style type="text/css" id="owaParaStyle"></style>
</head>
<body class="" style="word-wrap:break-word; line-break:after-white-space" fpstyle="1" ocsi="0">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">
<div>Hi Scott,&nbsp;</div>
<div><br>
</div>
<div>Are you on Windows? Did you specify the -in and -out flags? When I last tested it, the non-ASIO build doesn't support multi-channel audio. Also, the -dac flag needs an extra character before the number.</div>
<div><span style="font-size: 13.3333px;"><br>
</span></div>
<div><span style="font-size: 13.3333px;">If you start the ASIO build of ChucK like this, it works.</span></div>
<div><span style="font-family: verdana, arial, &quot;sans serif&quot;; font-size: 12px; background-color: rgb(239, 239, 239); color: blue;">chuckasio --dac_3 --adc3 --in8 --out8 test.ck</span><span style="font-family: verdana, arial, &quot;sans serif&quot;; font-size: 12px; background-color: rgb(239, 239, 239);">&nbsp;</span></div>
<span style="font-size: 13.3333px;">
<div><span style="font-size: 13.3333px;"><br>
</span></div>
<div><span style="font-size: 13.3333px;">Here, 3 is the audio device number.&nbsp;</span>See&nbsp;http://electro-music.com/forum/topic-69370.html<a href="http://electro-music.com/forum/topic-69370.html" target="_blank" style="font-size: 10pt;">http://electro-music.com/forum/topic-69370.html</a></div>
</span>
<div><br>
</div>
<div><span style="font-size: 10pt;">&nbsp; &nbsp;Hope this helps,</span></div>
<div><br>
</div>
<div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Doug</div>
<div><br>
</div>
<div><br>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div id="divRpF138485" style="direction: ltr;"><font face="Tahoma" size="2" color="#000000"><b>From:</b> chuck-users-bounces@lists.cs.princeton.edu [chuck-users-bounces@lists.cs.princeton.edu] on behalf of Scott Smallwood [ssmallwo@ualberta.ca]<br>
<b>Sent:</b> 18 February 2019 17:45<br>
<b>To:</b> ChucK Users Mailing List<br>
<b>Subject:</b> [chuck-users] Routing stereo sound file to dac channels<br>
</font><br>
</div>
<div></div>
<div>
<div class="">
<div class="">
<div class="">Dear chuckians…</div>
<div class=""><br class="">
</div>
<div class="">This is bizarre… I was sure I have done this in the past, but it isn’t working and now I’m a bit flummoxed…. Any ideas here?</div>
<div class=""><br class="">
</div>
<div class="">PS: &nbsp;I’m trying to route channels 0 and 1 of a stereo .wav file to dac channels 2 and 3. &nbsp;Should be simple. &nbsp;So why doesn’t this work??</div>
<div class=""><br class="">
</div>
<div class="">I realize that I could just spit it into mono files… but why? &nbsp;I thought SndBuf supported up to 8 channels.</div>
<div class=""><br class="">
</div>
<div class="">—</div>
<div class=""><br class="">
</div>
<div class="">
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(180,54,240); min-height:17px">
<br class="">
</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(180,54,240)">
SndBuf<span class="" style="color:rgb(0,0,0)">&nbsp;sb;</span></div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; min-height:17px">
<br class="">
</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; min-height:17px">
<span class="" style="color:rgb(114,158,18)">//read in stereo sound file</span></div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(81,81,81)">
&quot;snd/squeakies/bell_4.wav&quot;<span class="" style="color:rgb(114,158,18)">&nbsp;</span><span class="" style="color:rgb(0,0,0)">=&gt;</span><span class="" style="color:rgb(114,158,18)">&nbsp;</span><span class="" style="color:rgb(0,0,0)">sb.read;</span></div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; min-height:17px">
<br class="">
</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(114,158,18)">
//works - and routes channel 0 of sb to dac.chan(3)</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco">
sb.chan(<span class="" style="color:rgb(222,146,16)">0</span>)<span class="" style="color:rgb(114,158,18)">&nbsp;</span>=&gt;<span class="" style="color:rgb(114,158,18)">&nbsp;</span><span class="" style="color:rgb(4,51,255)">dac</span>.chan(<span class="" style="color:rgb(222,146,16)">2</span>);</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; min-height:17px">
<br class="">
</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(114,158,18)">
//doesn't work - claims NullPointerException</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco">
sb.chan(<span class="" style="color:rgb(222,146,16)">1</span>)<span class="" style="color:rgb(114,158,18)">&nbsp;</span>=&gt;<span class="" style="color:rgb(114,158,18)">&nbsp;</span><span class="" style="color:rgb(4,51,255)">dac</span>.chan(<span class="" style="color:rgb(222,146,16)">3</span>);</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; min-height:17px">
<br class="">
</div>
<div class="" style="margin:0px; font-size:13px; line-height:normal; font-family:Monaco; color:rgb(4,51,255)">
<span class="" style="color:rgb(222,146,16)">1</span><span class="" style="color:rgb(0,0,0)">::</span>minute<span class="" style="color:rgb(0,0,0)">&nbsp;=&gt;&nbsp;</span>now<span class="" style="color:rgb(0,0,0)">;</span></div>
</div>
</div>
<br class="">
<div class="">
<div class="" style="word-wrap:break-word; line-break:after-white-space">
<div class="" style="word-wrap:break-word; line-break:after-white-space">
<div class="" style="word-wrap:break-word; line-break:after-white-space">
<div class="" style="line-height:normal; orphans:2; widows:2; word-wrap:break-word; line-break:after-white-space">
<div class="" style="line-height:normal; word-wrap:break-word; line-break:after-white-space">
<div class="" style="line-height:normal; word-wrap:break-word; line-break:after-white-space">
<span class="Apple-style-span" style="border-collapse:separate; line-height:normal; border-spacing:0px">
<div class="" style="word-wrap:break-word; line-break:after-white-space"><span class="Apple-style-span" style="border-collapse:separate; line-height:normal; border-spacing:0px">
<div class="" style="word-wrap:break-word; line-break:after-white-space">—ss</div>
<div class="" style="word-wrap:break-word; line-break:after-white-space"><br class="">
</div>
<div class="" style="word-wrap:break-word; line-break:after-white-space">[ - ] &nbsp;<a href="http://www.scott-smallwood.com" class="" target="_blank">Scott Smallwood</a>&nbsp;- Associate Professor - University of Alberta &nbsp;[ - ]</div>
</span></div>
</span></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br class="">
<div class="">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); letter-spacing:normal; orphans:auto; text-align:start; text-indent:0px; text-transform:none; white-space:normal; widows:auto; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); font-family:Helvetica; font-style:normal; font-variant:normal; font-weight:normal; letter-spacing:normal; line-height:normal; orphans:2; text-indent:0px; text-transform:none; white-space:normal; widows:2; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); font-family:Helvetica; font-style:normal; font-variant:normal; font-weight:normal; letter-spacing:normal; line-height:normal; orphans:2; text-indent:0px; text-transform:none; white-space:normal; widows:2; word-spacing:0px; word-wrap:break-word">
<div class="" style="color:rgb(0,0,0); font-family:Helvetica; font-style:normal; font-variant:normal; font-weight:normal; letter-spacing:normal; line-height:normal; orphans:2; text-indent:0px; text-transform:none; white-space:normal; widows:2; word-spacing:0px; word-wrap:break-word">
<span class="Apple-style-span" style="border-collapse:separate; color:rgb(0,0,0); font-family:Helvetica; font-style:normal; font-variant:normal; font-weight:normal; letter-spacing:normal; line-height:normal; orphans:2; text-indent:0px; text-transform:none; white-space:normal; widows:2; word-spacing:0px; border-spacing:0px">
<div class="" style="word-wrap:break-word"><span class="Apple-style-span" style="border-collapse:separate; color:rgb(0,0,0); font-family:Helvetica; font-style:normal; font-variant:normal; font-weight:normal; letter-spacing:normal; line-height:normal; orphans:2; text-indent:0px; text-transform:none; white-space:normal; widows:2; word-spacing:0px; border-spacing:0px">
<div class="" style="word-wrap:break-word"><br class="">
</div>
</span></div>
</span></div>
</div>
</div>
</div>
</div>
</div>
</div>
<p><br>
-- </p>
<p><span style="color:#ff0000"><strong>TAKE CARE:</strong></span><strong> this message originates from an email service
<span style="color:#ff0000">outside of our University</span>. Do not click on any links or open attachments unless&nbsp;you recognise the sender and are absolutely sure that the content is safe</strong></p>
<p>&nbsp;</p>
</div>
</div>
</div>
</div>

<p><span style="font-family: Arial; font-size: small;"><br />-- <br />http://www.anglia.ac.uk/email-disclaimer<br /></span></p></body>
</html>