<div dir="ltr">George,<div><br></div><div>This has been a source of problems the past few versions as we have refactored WvOut to optimize real-time performance. That being said I can&#39;t reproduce this bug on Windows XP with chuck 1.3.3.0 or 1.3.4.0. I can&#39;t test on Windows 7 at the moment, but I may be able to try that a bit later. </div>
<div><br></div><div>A few ideas-</div><div><br></div><div>- Try an absolute path for the file path, or use me.dir():</div><div>me.dir() + &quot;/blerg.wav&quot; =&gt; string file;</div><div>There might be some strange file permissions issues happening if the destination file isn&#39;t in a directory chuck can write to. </div>
<div><br></div><div>- Try updating to the latest version of chuck/mini (1.3.4.0). </div><div><br></div><div>- Do you get the same results in the command line version of chuck as in miniAudicle? </div><div><br></div><div>spencer</div>
<div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sat, Jun 14, 2014 at 4:32 AM, Michael Heuer <span dir="ltr">&lt;<a href="mailto:heuermh@gmail.com" target="_blank">heuermh@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hello George,<br>
<br>
Your example seems to work fine for me on Windows XP<br>
<br>
$ chuck --version<br>
chuck version: 1.3.4.0 (chimera)<br>
   microsoft win32 : 32-bit<br>
   <a href="http://chuck.cs.princeton.edu/" target="_blank">http://chuck.cs.princeton.edu/</a><br>
   <a href="http://chuck.stanford.edu/" target="_blank">http://chuck.stanford.edu/</a><br>
<br>
$ cat <a href="http://blerg.ck" target="_blank">blerg.ck</a><br>
<div class="">SinOsc s =&gt; Gain g =&gt; dac;<br>
s.freq(400);<br>
g.gain(0.5);<br>
g =&gt; WvOut w =&gt; blackhole;<br>
&quot;blerg.wav&quot; =&gt; string file;<br>
w.wavFilename(file);<br>
1::second =&gt; now;<br>
w.closeFile(file); // what is the function of the argument here? can<br>
WvOut record multiple buffers at once?<br>
<br>
</div>$ chuck <a href="http://blerg.ck" target="_blank">blerg.ck</a><br>
<br>
blerg.wav opens fine in VLC, Audacity, and Reaper.<br>
<span class="HOEnZb"><font color="#888888"><br>
   michael<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
On Fri, Jun 13, 2014 at 11:39 AM, George Locke<br>
&lt;<a href="mailto:george.locke.maxmsp@gmail.com">george.locke.maxmsp@gmail.com</a>&gt; wrote:<br>
&gt; just going to bump this.  chuck can&#39;t record a wav!  what?!<br>
&gt;<br>
&gt; aifFilename is working, so at least I can record what I&#39;m doing.  but srsly,<br>
&gt; ppl, this is a major bug.<br>
&gt;<br>
&gt;  - George<br>
&gt;<br>
&gt;<br>
&gt; On Tue, Jun 10, 2014 at 5:02 PM, George Locke<br>
&gt; &lt;<a href="mailto:george.locke.maxmsp@gmail.com">george.locke.maxmsp@gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; Thanks for the reply.  I tried w.closeFile() (w/o the argument), and I<br>
&gt;&gt; tried ending the script with null @=&gt; w; and neither has helped.<br>
&gt;&gt;<br>
&gt;&gt; Regards,<br>
&gt;&gt; George<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; On Tue, Jun 10, 2014 at 4:43 PM, Tom Lieber &lt;<a href="mailto:tom@alltom.com">tom@alltom.com</a>&gt; wrote:<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; This probably isn’t helpful, but I’m using the same versions of ChucK and<br>
&gt;&gt;&gt; miniAudicle on OS X and the blerg.wav file looks fine.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; I’ve had trouble generating WAV files from miniAudicle in the past, but I<br>
&gt;&gt;&gt; think that was when I didn’t call closeFile() explicitly and ChucK never<br>
&gt;&gt;&gt; flushed.<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; I don’t think the argument to closeFile does anything, so I never provide<br>
&gt;&gt;&gt; it. :)<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; 2014-06-10 8:34 GMT-07:00 George Locke &lt;<a href="mailto:george.locke.maxmsp@gmail.com">george.locke.maxmsp@gmail.com</a>&gt;:<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Hi,<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; The output format of WvOut is coming out wrong.  Audacity doesn&#39;t<br>
&gt;&gt;&gt;&gt; recognize it as a wav (does not recognize type, suggests import raw), and<br>
&gt;&gt;&gt;&gt; windows media player rejects it as well.  Importing the file into Audacity<br>
&gt;&gt;&gt;&gt; as raw data works somewhat, but as I&#39;m diagnosing a dc-offset, I need an<br>
&gt;&gt;&gt;&gt; exact result.<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; here&#39;s some example code:<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; SinOsc s =&gt; Gain g =&gt; dac;<br>
&gt;&gt;&gt;&gt; s.freq(400);<br>
&gt;&gt;&gt;&gt; g.gain(0.5);<br>
&gt;&gt;&gt;&gt; g =&gt; WvOut w =&gt; blackhole;<br>
&gt;&gt;&gt;&gt; &quot;blerg.wav&quot; =&gt; string file;<br>
&gt;&gt;&gt;&gt; w.wavFilename(file);<br>
&gt;&gt;&gt;&gt; 1::second =&gt; now;<br>
&gt;&gt;&gt;&gt; w.closeFile(file); // what is the function of the argument here? can<br>
&gt;&gt;&gt;&gt; WvOut record multiple buffers at once?<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; I&#39;m not so experienced with chuck but experienced in &quot;normal&quot; computer<br>
&gt;&gt;&gt;&gt; programming.  Running miniAudicle 1.3.1 with chuck 1.3.3.0 on windows 7 pro<br>
&gt;&gt;&gt;&gt; sp1 (32 bit).<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; Thanks,<br>
&gt;&gt;&gt;&gt; George<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;&gt; _______________________________________________<br>
&gt;&gt;&gt;&gt; chuck-users mailing list<br>
&gt;&gt;&gt;&gt; <a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
&gt;&gt;&gt;&gt; <a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
&gt;&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; --<br>
&gt;&gt;&gt; Tom Lieber<br>
&gt;&gt;&gt; <a href="http://AllTom.com/" target="_blank">http://AllTom.com/</a><br>
&gt;&gt;&gt; <a href="http://infinite-sketchpad.com/" target="_blank">http://infinite-sketchpad.com/</a><br>
&gt;&gt;&gt;<br>
&gt;&gt;&gt; _______________________________________________<br>
&gt;&gt;&gt; chuck-users mailing list<br>
&gt;&gt;&gt; <a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
&gt;&gt;&gt; <a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
&gt;&gt;&gt;<br>
&gt;&gt;<br>
&gt;<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; chuck-users mailing list<br>
&gt; <a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
&gt; <a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
&gt;<br>
_______________________________________________<br>
chuck-users mailing list<br>
<a href="mailto:chuck-users@lists.cs.princeton.edu">chuck-users@lists.cs.princeton.edu</a><br>
<a href="https://lists.cs.princeton.edu/mailman/listinfo/chuck-users" target="_blank">https://lists.cs.princeton.edu/mailman/listinfo/chuck-users</a><br>
<br>
</div></div></blockquote></div><br></div>