<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<id>tag:www.nabble.com,2006:forum-527</id>
	<title>Nabble - SoX</title>
	<updated>2008-09-05T10:18:25Z</updated>
	<link rel="self" type="application/atom+xml" href="http://www.nabble.com/SoX-f527.xml" />
	<link rel="alternate" type="text/html" href="http://www.nabble.com/SoX-f527.html" />
	<subtitle type="html"></subtitle>
	
<entry>
	<id>tag:www.nabble.com,2006:post-19335842</id>
	<title>Re: A question about libsox</title>
	<published>2008-09-05T10:18:25Z</published>
	<updated>2008-09-05T10:18:25Z</updated>
	<author>
		<name>robs-5</name>
	</author>
	<content type="html">--- On Fri, 5/9/08, Evgeny F &amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19335842&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;evgeny.fursov@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt; &amp;quot;It processes the input buffer into the out-
&lt;br&gt;&amp;gt; put buffer, and sets the size variables to the num-
&lt;br&gt;&amp;gt; bers of samples actually processed.	It is under no
&lt;br&gt;&amp;gt; obligation &amp;nbsp;to &amp;nbsp;read from the input buffer or write
&lt;br&gt;&amp;gt; to the output buffer during the same call.&amp;quot;
&lt;br&gt;&lt;br&gt;Ah yes, the documentation might need to be clarified; &amp;nbsp;IIRC the situation is as follows: as above for effects not at the end of the chain (the rationale being that if an effect's output buffer is full then it may not be able to process all of its input buffer); however, the `effect' at the end of the chain is a special effect for outputting the audio; it has no output buffer (in the chain that is) to get full, so it must consume all its input.
&lt;br&gt;&lt;br&gt;Hope this helps,
&lt;br&gt;Rob
&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19335842&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/A-question-about-libsox-tp19287511p19335842.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19328440</id>
	<title>Re: A question about libsox</title>
	<published>2008-09-05T03:18:32Z</published>
	<updated>2008-09-05T03:18:32Z</updated>
	<author>
		<name>Evgeny F</name>
	</author>
	<content type="html">At last I've managed to solve my problem using slightly different approach, but thanks for your answer anyway, Chris.
&lt;br&gt;&lt;br&gt;There is another interesting thing I've run into during my experimentations.
&lt;br&gt;In the libsox documentation where is one thing written about effect handler's flow function:
&lt;br&gt;&lt;br&gt;&amp;quot;It processes the input buffer into the out-
&lt;br&gt;put buffer, and sets the size variables to the num-
&lt;br&gt;bers of samples actually processed.	It is under no
&lt;br&gt;obligation &amp;nbsp;to &amp;nbsp;read from the input buffer or write
&lt;br&gt;to the output buffer during the same call.&amp;quot;
&lt;br&gt;&lt;br&gt;I've just added the following line at the beginning of output_flow() in exaple1.c :
&lt;br&gt;if (*isamp &amp;gt; 1024) *isamp = 1024;
&lt;br&gt;&lt;br&gt;I thought if my output handler processes only a portion of its input data, it should work perfectly fine with the same results, only libsox framework will call output_flow() few more times to process all the data.
&lt;br&gt;&lt;br&gt;But surprisingly I was wrong - exaple1 execution failed with &amp;quot;Premature EOF on .wav input file&amp;quot; message. Looks confusing for me :)
&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/A-question-about-libsox-tp19287511p19328440.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19297866</id>
	<title>Re: one question about basic terms</title>
	<published>2008-09-03T13:50:07Z</published>
	<updated>2008-09-03T13:50:07Z</updated>
	<author>
		<name>real.self@gmail.com</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;For my next question like this, I am going to post it to the development mail list. Thanks for notifying me this. Chris.&amp;nbsp;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Jiangfan&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Wed, Sep 3, 2008 at 3:45 PM, real self &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297866&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;real.self@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;&lt;div dir=&quot;ltr&quot;&gt;Thanks for your answer, Chris.&amp;nbsp;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;But I am still wondering if you can point me to some specific math/science&amp;nbsp;references. Currently I followed some links in Sox website, but they are not specific and detail enough to give me the final formula like the contrast formula.&lt;/div&gt;
&lt;div class=&quot;Ih2E3d&quot;&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;Thanks for your consideration for the newbie like me.&amp;nbsp;&lt;/div&gt;

&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Jiangfan&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;Wj3C7c&quot;&gt;&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Wed, Sep 3, 2008 at 2:49 PM, Chris Bagwell &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297866&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;chris@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;
&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex&quot;&gt;
This one should better be discussed in sox-devel as well but...&lt;br&gt;
&lt;div&gt;&lt;br&gt;
On Wed, Sep 03, 2008 at 12:15:13PM -0500, real self wrote:&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt; I am trying to convert the Sox to a Java version for my PhD dissertation.&lt;br&gt;
&amp;gt; But I encounter some basic problems because I am a newbie for the audio&lt;br&gt;
&amp;gt; effect programming.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; The contrast code snippet is shown below as the discussion basis.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; ============The flow function in the contrast effect==========&lt;br&gt;
&amp;gt; static int flow(sox_effect_t * effp, const sox_sample_t * ibuf,&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; sox_sample_t * obuf, sox_size_t * isamp, sox_size_t * osamp)&lt;br&gt;
&amp;gt; {&lt;br&gt;
&amp;gt; &amp;nbsp; priv_t * p = (priv_t *)effp-&amp;gt;priv;&lt;br&gt;
&amp;gt; &amp;nbsp; sox_size_t len = *isamp = *osamp = min(*isamp, *osamp);&lt;br&gt;
&amp;gt; &amp;nbsp; while (len--) {&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;
&amp;gt; &amp;nbsp; }&lt;br&gt;
&amp;gt; &amp;nbsp; return SOX_SUCCESS;&lt;br&gt;
&amp;gt; }&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; ============The flow function in the contrast effect==========&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I have several questions as following:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 1. The ibuf is the input audio data stream and the obuf is the output audio&lt;br&gt;
&amp;gt; data stream after this processing. Am I right?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;yes.&lt;br&gt;
&lt;div&gt;&amp;gt;&lt;br&gt;
&amp;gt; 2. Why do we use isamp and osamp? I am not familiar with the sample or&lt;br&gt;
&amp;gt; clipping terms, so could you please give me a simple explanation? &amp;nbsp;Is the&lt;br&gt;
&amp;gt; sample describes the ibuf?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;isamp is # of samples passed in via ibuf. &amp;nbsp;osamp is used to let&lt;br&gt;
others now how many samples the effect placed into obuf.&lt;br&gt;
&lt;br&gt;
I hope to improve the libsox.txt files with a little better&lt;br&gt;
info on the effects soon.&lt;br&gt;
&lt;div&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 3. There are many lsx_x related functions, such as lsx_usage(). Where do I&lt;br&gt;
&amp;gt; find these kind of utilities?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;You&amp;#39;ll just have to search the source code for them. &amp;nbsp;They are include&lt;br&gt;
with sox source along with the effects.&lt;br&gt;
&lt;div&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 4. One last and important question is that you must have a reference to&lt;br&gt;
&amp;gt; develop these audio effects. For example, you have the following formula for&lt;br&gt;
&amp;gt; the contrast audio effect.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I wonder if you can point me to that reference so that I could find these&lt;br&gt;
&amp;gt; basic formulas.&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;That one is easy... There is no single reference for this type information&lt;br&gt;
that can be provided. &amp;nbsp;It comes from lots of math/science fields.&lt;br&gt;
&lt;br&gt;
Chris&lt;br&gt;
&lt;br&gt;
-------------------------------------------------------------------------&lt;br&gt;
This SF.Net email is sponsored by the Moblin Your Move Developer&amp;#39;s challenge&lt;br&gt;
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes&lt;br&gt;
Grand prize is a trip for two to an Open Source event anywhere in the world&lt;br&gt;
&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;&lt;br&gt;
_______________________________________________&lt;br&gt;
Sox-users mailing list&lt;br&gt;
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297866&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;&lt;br&gt;
&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;
&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;
&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;&lt;/div&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297866&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/one-question-about-basic-terms-tp19293750p19297866.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19297787</id>
	<title>Re: one question about basic terms</title>
	<published>2008-09-03T13:45:01Z</published>
	<updated>2008-09-03T13:45:01Z</updated>
	<author>
		<name>real.self@gmail.com</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;Thanks for your answer, Chris.&amp;nbsp;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;But I am still wondering if you can point me to some specific math/science&amp;nbsp;references. Currently I followed some links in Sox website, but they are not specific and detail enough to give me the final formula like the contrast formula.&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Thanks for your consideration for the newbie like me.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Jiangfan&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Wed, Sep 3, 2008 at 2:49 PM, Chris Bagwell &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297787&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;chris@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;&quot;&gt;
This one should better be discussed in sox-devel as well but...&lt;br&gt;
&lt;div class=&quot;Ih2E3d&quot;&gt;&lt;br&gt;
On Wed, Sep 03, 2008 at 12:15:13PM -0500, real self wrote:&lt;br&gt;
&amp;gt; Hi,&lt;br&gt;
&amp;gt; I am trying to convert the Sox to a Java version for my PhD dissertation.&lt;br&gt;
&amp;gt; But I encounter some basic problems because I am a newbie for the audio&lt;br&gt;
&amp;gt; effect programming.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; The contrast code snippet is shown below as the discussion basis.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; ============The flow function in the contrast effect==========&lt;br&gt;
&amp;gt; static int flow(sox_effect_t * effp, const sox_sample_t * ibuf,&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; sox_sample_t * obuf, sox_size_t * isamp, sox_size_t * osamp)&lt;br&gt;
&amp;gt; {&lt;br&gt;
&amp;gt; &amp;nbsp; priv_t * p = (priv_t *)effp-&amp;gt;priv;&lt;br&gt;
&amp;gt; &amp;nbsp; sox_size_t len = *isamp = *osamp = min(*isamp, *osamp);&lt;br&gt;
&amp;gt; &amp;nbsp; while (len--) {&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;
&amp;gt; &amp;nbsp; }&lt;br&gt;
&amp;gt; &amp;nbsp; return SOX_SUCCESS;&lt;br&gt;
&amp;gt; }&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; ============The flow function in the contrast effect==========&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I have several questions as following:&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 1. The ibuf is the input audio data stream and the obuf is the output audio&lt;br&gt;
&amp;gt; data stream after this processing. Am I right?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;yes.&lt;br&gt;
&lt;div class=&quot;Ih2E3d&quot;&gt;&amp;gt;&lt;br&gt;
&amp;gt; 2. Why do we use isamp and osamp? I am not familiar with the sample or&lt;br&gt;
&amp;gt; clipping terms, so could you please give me a simple explanation? &amp;nbsp;Is the&lt;br&gt;
&amp;gt; sample describes the ibuf?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;isamp is # of samples passed in via ibuf. &amp;nbsp;osamp is used to let&lt;br&gt;
others now how many samples the effect placed into obuf.&lt;br&gt;
&lt;br&gt;
I hope to improve the libsox.txt files with a little better&lt;br&gt;
info on the effects soon.&lt;br&gt;
&lt;div class=&quot;Ih2E3d&quot;&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 3. There are many lsx_x related functions, such as lsx_usage(). Where do I&lt;br&gt;
&amp;gt; find these kind of utilities?&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;You&amp;#39;ll just have to search the source code for them. &amp;nbsp;They are include&lt;br&gt;
with sox source along with the effects.&lt;br&gt;
&lt;div class=&quot;Ih2E3d&quot;&gt;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; 4. One last and important question is that you must have a reference to&lt;br&gt;
&amp;gt; develop these audio effects. For example, you have the following formula for&lt;br&gt;
&amp;gt; the contrast audio effect.&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;br&gt;
&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;br&gt;
&amp;gt;&lt;br&gt;
&amp;gt; I wonder if you can point me to that reference so that I could find these&lt;br&gt;
&amp;gt; basic formulas.&lt;br&gt;
&amp;gt;&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;That one is easy... There is no single reference for this type information&lt;br&gt;
that can be provided. &amp;nbsp;It comes from lots of math/science fields.&lt;br&gt;
&lt;br&gt;
Chris&lt;br&gt;
&lt;br&gt;
-------------------------------------------------------------------------&lt;br&gt;
This SF.Net email is sponsored by the Moblin Your Move Developer&amp;#39;s challenge&lt;br&gt;
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes&lt;br&gt;
Grand prize is a trip for two to an Open Source event anywhere in the world&lt;br&gt;
&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;&lt;br&gt;
_______________________________________________&lt;br&gt;
Sox-users mailing list&lt;br&gt;
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297787&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;&lt;br&gt;
&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;
&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;&lt;/div&gt;&lt;/div&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19297787&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/one-question-about-basic-terms-tp19293750p19297787.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19296702</id>
	<title>Re: one question about basic terms</title>
	<published>2008-09-03T12:49:55Z</published>
	<updated>2008-09-03T12:49:55Z</updated>
	<author>
		<name>Chris Bagwell</name>
	</author>
	<content type="html">This one should better be discussed in sox-devel as well but...
&lt;br&gt;&lt;br&gt;On Wed, Sep 03, 2008 at 12:15:13PM -0500, real self wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Hi,
&lt;br&gt;&amp;gt; I am trying to convert the Sox to a Java version for my PhD dissertation.
&lt;br&gt;&amp;gt; But I encounter some basic problems because I am a newbie for the audio
&lt;br&gt;&amp;gt; effect programming.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; The contrast code snippet is shown below as the discussion basis.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ============The flow function in the contrast effect==========
&lt;br&gt;&amp;gt; static int flow(sox_effect_t * effp, const sox_sample_t * ibuf,
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; sox_sample_t * obuf, sox_size_t * isamp, sox_size_t * osamp)
&lt;br&gt;&amp;gt; {
&lt;br&gt;&amp;gt; &amp;nbsp; priv_t * p = (priv_t *)effp-&amp;gt;priv;
&lt;br&gt;&amp;gt; &amp;nbsp; sox_size_t len = *isamp = *osamp = min(*isamp, *osamp);
&lt;br&gt;&amp;gt; &amp;nbsp; while (len--) {
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;
&lt;br&gt;&amp;gt; &amp;nbsp; }
&lt;br&gt;&amp;gt; &amp;nbsp; return SOX_SUCCESS;
&lt;br&gt;&amp;gt; }
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ============The flow function in the contrast effect==========
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I have several questions as following:
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 1. The ibuf is the input audio data stream and the obuf is the output audio
&lt;br&gt;&amp;gt; data stream after this processing. Am I right?
&lt;/div&gt;&lt;br&gt;yes.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 2. Why do we use isamp and osamp? I am not familiar with the sample or
&lt;br&gt;&amp;gt; clipping terms, so could you please give me a simple explanation? &amp;nbsp;Is the
&lt;br&gt;&amp;gt; sample describes the ibuf?
&lt;br&gt;&lt;br&gt;isamp is # of samples passed in via ibuf. &amp;nbsp;osamp is used to let
&lt;br&gt;others now how many samples the effect placed into obuf.
&lt;br&gt;&lt;br&gt;I hope to improve the libsox.txt files with a little better
&lt;br&gt;info on the effects soon.
&lt;br&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 3. There are many lsx_x related functions, such as lsx_usage(). Where do I
&lt;br&gt;&amp;gt; find these kind of utilities?
&lt;br&gt;&lt;br&gt;You'll just have to search the source code for them. &amp;nbsp;They are include
&lt;br&gt;with sox source along with the effects.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 4. One last and important question is that you must have a reference to
&lt;br&gt;&amp;gt; develop these audio effects. For example, you have the following formula for
&lt;br&gt;&amp;gt; the contrast audio effect.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; *obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I wonder if you can point me to that reference so that I could find these
&lt;br&gt;&amp;gt; basic formulas.
&lt;br&gt;&amp;gt; 
&lt;/div&gt;&lt;br&gt;That one is easy... There is no single reference for this type information
&lt;br&gt;that can be provided. &amp;nbsp;It comes from lots of math/science fields.
&lt;br&gt;&lt;br&gt;Chris
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19296702&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/one-question-about-basic-terms-tp19293750p19296702.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19296534</id>
	<title>Re: A question about libsox</title>
	<published>2008-09-03T12:41:29Z</published>
	<updated>2008-09-03T12:41:29Z</updated>
	<author>
		<name>Chris Bagwell</name>
	</author>
	<content type="html">On Wed, Sep 03, 2008 at 04:36:59AM -0700, Evgeny F wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Hello.
&lt;br&gt;&amp;gt; I'm using libsox in my simple audio conversion application and have
&lt;br&gt;&amp;gt; encountered a problem which I could not solve.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; In my application I've created the following effects chain:
&lt;br&gt;&amp;gt; effect 0: my_input_effect
&lt;br&gt;&amp;gt; effect 1: &amp;quot;rate&amp;quot;
&lt;br&gt;&amp;gt; effect 2: my_output effect
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; my_input_effect and my_output effects are working like corresponding effects
&lt;br&gt;&amp;gt; in example1 of sox package, but my_input_effect gets data from some
&lt;br&gt;&amp;gt; input_buffer and my_output effects fills output_buffer with output data.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I have the following main processing loop (in pseudocode):
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; loop {
&lt;br&gt;&amp;gt; &amp;nbsp; fill_input_buffer();
&lt;br&gt;&amp;gt; &amp;nbsp; sox_flow_effects(my_chain, 0);
&lt;br&gt;&amp;gt; &amp;nbsp; handle_output_buffer();
&lt;br&gt;&amp;gt; }
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; When running my app I got interesting results:
&lt;br&gt;&amp;gt; The first loop iteration passes fine: I got all the expected data in my
&lt;br&gt;&amp;gt; output buffer.
&lt;br&gt;&amp;gt; The next few iterations (exact number depends on chosen input buffer size)
&lt;br&gt;&amp;gt; generate no output data at all - my_output effect recieves 0 input samples.
&lt;/div&gt;&lt;br&gt;This should probably better be discussed in sox-devel list but here
&lt;br&gt;goes anyways.
&lt;br&gt;&lt;br&gt;I think we are probably missing some information to fully understand
&lt;br&gt;what the issue is. &amp;nbsp;For example, what is the condition occuring
&lt;br&gt;that causing your loop to restart?
&lt;br&gt;&lt;br&gt;A guess is that an effect went into drain mode (either input effect
&lt;br&gt;or rate). &amp;nbsp;Once all samples are drained to output file, future calls
&lt;br&gt;to sox_flow_effects() would still send zero data to output effect
&lt;br&gt;unless you restart the effects chain. &amp;nbsp;It should be returning
&lt;br&gt;SOX_EOF though to left you know your in drain mode.
&lt;br&gt;&lt;br&gt;There happens to be sample code for this concept in sox.c. &amp;nbsp;For
&lt;br&gt;14.0.x series, search for sox_sequence. &amp;nbsp;In current cvs (or 4.1.x),
&lt;br&gt;look for that and also sox_multiple.
&lt;br&gt;&lt;br&gt;sox_sequence is a special case for handling input EOF in a loop and
&lt;br&gt;sox_multiple is special case for handling creating a new output
&lt;br&gt;file each time an effect goes into drain mode. &amp;nbsp;sox_multiple
&lt;br&gt;can also restart specific effects without restarting the whole chain.
&lt;br&gt;&lt;br&gt;Chris
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19296534&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/A-question-about-libsox-tp19287511p19296534.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19293750</id>
	<title>one question about basic terms</title>
	<published>2008-09-03T10:15:13Z</published>
	<updated>2008-09-03T10:15:13Z</updated>
	<author>
		<name>real.self@gmail.com</name>
	</author>
	<content type="html">&lt;div dir=&quot;ltr&quot;&gt;Hi,&amp;nbsp;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;I am trying to convert the Sox to a Java version for my PhD&amp;nbsp;dissertation. But I encounter some basic problems because I am a&amp;nbsp;newbie for the audio effect programming.&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;
&lt;div&gt;The contrast code snippet is shown below as the&amp;nbsp;discussion&amp;nbsp;basis.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;============The flow&amp;nbsp;function&amp;nbsp;in the contrast effect==========&lt;/div&gt;&lt;div&gt;&lt;div&gt;static int flow(sox_effect_t * effp, const sox_sample_t * ibuf,&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;sox_sample_t * obuf, sox_size_t * isamp, sox_size_t * osamp)&lt;/div&gt;&lt;div&gt;{&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp;priv_t * p = (priv_t *)effp-&amp;gt;priv;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp;sox_size_t len = *isamp = *osamp = min(*isamp, *osamp);&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp;while (len--) {&lt;/div&gt;
&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;*obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp;}&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp;return SOX_SUCCESS;&lt;/div&gt;&lt;div&gt;}&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;&lt;div&gt;
============The flow&amp;nbsp;function&amp;nbsp;in the contrast effect==========&lt;/div&gt;&lt;div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;I have several questions as following:&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;1. The ibuf is the input audio data stream and the obuf is the output audio data stream after this processing. Am I right?&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;2. Why do we use isamp and osamp? I am not&amp;nbsp;familiar&amp;nbsp;with the sample or clipping terms, so could you please give me a simple explanation? &amp;nbsp;Is the sample describes the ibuf?&amp;nbsp;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;3. There are many&amp;nbsp;lsx_x related functions, such as&amp;nbsp;lsx_usage(). Where do I find these kind of utilities?&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;4. One last and important question is that you must have a reference to develop these audio effects. For example, you have the following formula for the contrast audio effect.&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;
&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp; double d = *ibuf++ * (-M_PI_2 / SOX_SAMPLE_MIN);&lt;/div&gt;&lt;div&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;*obuf++ = sin(d + p-&amp;gt;contrast * sin(d * 4)) * SOX_SAMPLE_MAX;&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;I wonder if you can point me to that reference so that I could find these basic formulas.&amp;nbsp;&lt;/div&gt;
&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;At last, thanks you very much for your help. It is highly appreciated!&lt;/div&gt;&lt;div&gt;&lt;br&gt;&lt;/div&gt;&lt;div&gt;Jiangfan Shi&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19293750&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/one-question-about-basic-terms-tp19293750p19293750.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19287511</id>
	<title>A question about libsox</title>
	<published>2008-09-03T04:36:58Z</published>
	<updated>2008-09-03T04:36:58Z</updated>
	<author>
		<name>Evgeny F</name>
	</author>
	<content type="html">Hello.
&lt;br&gt;I'm using libsox in my simple audio conversion application and have encountered a problem which I could not solve.
&lt;br&gt;&lt;br&gt;In my application I've created the following effects chain:
&lt;br&gt;effect 0: my_input_effect
&lt;br&gt;effect 1: &amp;quot;rate&amp;quot;
&lt;br&gt;effect 2: my_output effect
&lt;br&gt;&lt;br&gt;my_input_effect and my_output effects are working like corresponding effects in example1 of sox package, but my_input_effect gets data from some input_buffer and my_output effects fills output_buffer with output data.
&lt;br&gt;&lt;br&gt;I have the following main processing loop (in pseudocode):
&lt;br&gt;&lt;br&gt;loop {
&lt;br&gt;&amp;nbsp; fill_input_buffer();
&lt;br&gt;&amp;nbsp; sox_flow_effects(my_chain, 0);
&lt;br&gt;&amp;nbsp; handle_output_buffer();
&lt;br&gt;}
&lt;br&gt;&lt;br&gt;When running my app I got interesting results:
&lt;br&gt;The first loop iteration passes fine: I got all the expected data in my output buffer.
&lt;br&gt;The next few iterations (exact number depends on chosen input buffer size) generate no output data at all - my_output effect recieves 0 input samples. It looks like &amp;quot;rate&amp;quot; effect completely consumes them.
&lt;br&gt;And at last all the remaining loop iterations again do their job perfectly - my output buffer gets filled in.
&lt;br&gt;&lt;br&gt;I've converted WAV PCM file with my app (few minutes length) and got nicely resampled file but with a short gap at the beginning.
&lt;br&gt;&lt;br&gt;So, my question: can libsox be used in the way I'm trying to use it, and if it can, what am I doing possibly wrong?
&lt;br&gt;(I'm developing for win32 using VisualStudio 2005)</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/A-question-about-libsox-tp19287511p19287511.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19259964</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-09-01T13:01:05Z</published>
	<updated>2008-09-01T13:01:05Z</updated>
	<author>
		<name>Mike Hirst</name>
	</author>
	<content type="html">Thanks Jim,
&lt;br&gt;&lt;br&gt;I'd love to take credit for this, but it's a trick that often comes up 
&lt;br&gt;on sed-users for getting fixed-width output from a sed script. The same 
&lt;br&gt;trick also comes up in Sal mangano's XSLT Cookbook.
&lt;br&gt;&lt;br&gt;Any way, good luck with your project. I note that you are using Java to 
&lt;br&gt;generate a windows batch file. I've already worked out in my head how 
&lt;br&gt;you could do this, so I guess you could do the same.
&lt;br&gt;&lt;br&gt;Best Wishes
&lt;br&gt;&lt;br&gt;Mike Hirst
&lt;br&gt;&lt;br&gt;Jim O'Flaherty wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Mike,
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Nice. That is quite clever. Thank you very much. And that is even 
&lt;br&gt;&amp;gt; parallel-izable (for when I scale this up to a server load).
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; This technique assumes that all my tracks remain under 16 seconds (which 
&lt;br&gt;&amp;gt; I am not able to guarantee). So, to generify the technique, I would just 
&lt;br&gt;&amp;gt; compute the smallest multiple of 8 larger than the longest track (ex: 
&lt;br&gt;&amp;gt; longest track is 17 seconds, therefor s=24 so m=3), create a track of 
&lt;br&gt;&amp;gt; silence s seconds long, then append that to every file, clipping each 
&lt;br&gt;&amp;gt; files back to s total seconds. And then have m number of tracks each 
&lt;br&gt;&amp;gt; being appended in parallel (of which I am appending every mth file). And 
&lt;br&gt;&amp;gt; then mix the appended tracks together to create my final track. And I 
&lt;br&gt;&amp;gt; can automate all that in my Java code which is dynamically generating 
&lt;br&gt;&amp;gt; the Windows batch file.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I'm looking forward to implementing this.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Jim
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Mike Hirst wrote:
&lt;br&gt;&amp;gt;&amp;gt; Jim,
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; If all short files were less than 8 secs, it would be easy to add 
&lt;br&gt;&amp;gt;&amp;gt; silence to each short file to make 8 secs and then join them together. 
&lt;br&gt;&amp;gt;&amp;gt; The problem here is that some files are longer than 8 secs. They are, 
&lt;br&gt;&amp;gt;&amp;gt; however, shorter than 16 secs. Here's my suggestion.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 1. Make two short files. One of 16 secs silence and the other 8 secs 
&lt;br&gt;&amp;gt;&amp;gt; silence.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 2. concat the 16 secs file to the end of each of the short files (clips).
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; clip................
&lt;br&gt;&amp;gt;&amp;gt; longclip................
&lt;br&gt;&amp;gt;&amp;gt; verylongclip................
&lt;br&gt;&amp;gt;&amp;gt; etc
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 3. Trim the concatenated files (clips) to 16 secs
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; clip............
&lt;br&gt;&amp;gt;&amp;gt; longclip........
&lt;br&gt;&amp;gt;&amp;gt; verylongclip....
&lt;br&gt;&amp;gt;&amp;gt; etc
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 4. Concat half the trimmed 16 sec files Clips).
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; clip............longclip........verylongclip.... etc
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 5. Concat the 8 sec silence followed by the other half of the trimmed 16 
&lt;br&gt;&amp;gt;&amp;gt; sec files (clips).
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; ........clip............longclip........verylongclip.... etc
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; 6. Mix the two concatenated sequences.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; clip............longclip........verylongclip....
&lt;br&gt;&amp;gt;&amp;gt; ........clip............longclip........verylongclip.... etc
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; The result should be an audio clip starting every 8 secs. All clips play 
&lt;br&gt;&amp;gt;&amp;gt; for their full duration, with clips of over 8 secs continuing to play 
&lt;br&gt;&amp;gt;&amp;gt; after the start of the next 8 sec sequence.
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Jim O'Flaherty wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Mike,
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Are you asking what the maximum length of the smallest file is? If so, 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; it's 1.5 seconds. The files average around 6.75 seconds in length with 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; no file being the same size as any other. However, the valley is 1.5 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; seconds and the peak is 10.2 seconds. And neither the peaks nor valleys 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; are uniform.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; BTW, I have since gotten FLAC to work as it is available without having 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; to provide a library in the standard windows distribution. So, my 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; initial technique described in A is working, albeit pretty slowly 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; towards the end of the 20 minutes. However, the FLAC solutions 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; substantially faster than the .WAV solution I was using.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Once I have my basic functionality complete and I am producing the 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; output I desire, I am going to return and start working the efficiency 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; issue. The model I am considering is using what Chris suggested on all 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; files less than 8 seconds (rounding them to 8 seconds). And then 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; appending all the files, substituting a over-sized files (greater than 8 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; seconds) with 8 seconds of silence. And then I will then use &amp;quot;pad&amp;quot; on 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; the remaining +8 second files. And then mix each of those into the 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; master &amp;quot;appended&amp;quot; file. That seems like it will take the least amount of 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; processing and file writing.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Jim
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Mike Hirst wrote:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; What is the maximum length of small file?
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Jim O'Flaherty wrote:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Hi,
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I have a project where I am taking a series of small sound files (.wav) 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; and attempting to combine them into a single .wav file. In a specific 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; order and at every 8 second marker starting from 0, I need one of these 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; small sound files to play until it completes (typically in less than 8 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; seconds). And then on the next 8 second marker, another small sound file 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; plays. I have 140 these spanning 20 minutes.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; My first approach was to take each of the small sound files and prepend 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; (using &amp;quot;pad&amp;quot;) a number of seconds to the file. However, by the time it 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; got to the 40th file, what was a small sound file before (~422K) was 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; growing into the 10s of MB. I think this is because the output was a 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; .wav and there is no compression in a .wav file. Here's an example 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Windows DOS command line entry:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; %SOX% %PATH_SS%\024.wav %PATH_TEMP%\024_silence40.wav pad 304.000 norm
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; I am not stuck with .wav except as my input type. I want to experiment 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; with using .flac. However, apparently some optional library is required. 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; And, I have looked all over the SOX site and have not been able to 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; figure out what that library might be, where to find it and what to do 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; with it once I found it. I then went to the FLAC site. That was no help 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; as there were no SOX references there.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; So some questions:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; A) Is taking each of the 140 files and prepending it with (n * 8 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; seconds of) silence (using the &amp;quot;pad&amp;quot; option) and then mixing the 140 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; tracks together the proper way to approach generating the desired output 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; of 140 small samples each playing at an 8 second interval? And what 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; other options in SOX might there be to achieving this same effect?
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; B) How much will FLAC speed up the processing? Using .wav as my 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; output, saving tracks with 320 second of silence was taking 10s of 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; seconds due to the file being 10s of MB large.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; C) Where can I go to find out what to dl and where to place it 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; regarding the FLAC library so that SOX can use it?
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Thank you,
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Jim
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19259964&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19259964&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19259964&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;Mike Hirst
&lt;br&gt;Managing Director
&lt;br&gt;DAS-360°
&lt;br&gt;16 Ocean View
&lt;br&gt;Whitley Bay
&lt;br&gt;Tyne &amp; Wear
&lt;br&gt;NE26 1AL
&lt;br&gt;&lt;br&gt;tel: 0191 289 3186
&lt;br&gt;email: &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19259964&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mike.hirst@...&lt;/a&gt;
&lt;br&gt;web: &lt;a href=&quot;http://www.das360.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.das360.net&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19259964&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19259964.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19258408</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-09-01T10:51:00Z</published>
	<updated>2008-09-01T10:51:00Z</updated>
	<author>
		<name>Jim O'Flaherty</name>
	</author>
	<content type="html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
&lt;/head&gt;
&lt;body bgcolor=&quot;#ffffff&quot; text=&quot;#000000&quot;&gt;
Mike,&lt;br&gt;
&lt;br&gt;
Nice. That is quite clever. Thank you very much. And that is even
parallel-izable (for when I scale this up to a server load).&lt;br&gt;
&lt;br&gt;
This technique assumes that all my tracks remain under 16 seconds
(which I am not able to guarantee). So, to generify the technique, I
would just compute the smallest multiple of 8 larger than the longest
track (ex: longest track is 17 seconds, therefor s=24 so m=3), create a
track of silence s seconds long, then append that to every file,
clipping each files back to s total seconds. And then have m number of
tracks each being appended in parallel (of which I am appending every
mth file). And then mix the appended tracks together to create my final
track. And I can automate all that in my Java code which is dynamically
generating the Windows batch file.&lt;br&gt;
&lt;br&gt;
I'm looking forward to implementing this.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Mike Hirst wrote:
&lt;blockquote cite=&quot;mid:48BC13A1.8030304@blueyonder.co.uk&quot; type=&quot;cite&quot;&gt;
  &lt;pre wrap=&quot;&quot;&gt;Jim,

If all short files were less than 8 secs, it would be easy to add 
silence to each short file to make 8 secs and then join them together. 
The problem here is that some files are longer than 8 secs. They are, 
however, shorter than 16 secs. Here's my suggestion.

1. Make two short files. One of 16 secs silence and the other 8 secs 
silence.

2. concat the 16 secs file to the end of each of the short files (clips).

clip................
longclip................
verylongclip................
etc

3. Trim the concatenated files (clips) to 16 secs

clip............
longclip........
verylongclip....
etc

4. Concat half the trimmed 16 sec files Clips).

clip............longclip........verylongclip.... etc

5. Concat the 8 sec silence followed by the other half of the trimmed 16 
sec files (clips).

........clip............longclip........verylongclip.... etc

6. Mix the two concatenated sequences.

clip............longclip........verylongclip....
........clip............longclip........verylongclip.... etc

The result should be an audio clip starting every 8 secs. All clips play 
for their full duration, with clips of over 8 secs continuing to play 
after the start of the next 8 sec sequence.

Jim O'Flaherty wrote:
  &lt;/pre&gt;
  &lt;blockquote type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;Mike,

Are you asking what the maximum length of the smallest file is? If so, 
it's 1.5 seconds. The files average around 6.75 seconds in length with 
no file being the same size as any other. However, the valley is 1.5 
seconds and the peak is 10.2 seconds. And neither the peaks nor valleys 
are uniform.

BTW, I have since gotten FLAC to work as it is available without having 
to provide a library in the standard windows distribution. So, my 
initial technique described in A is working, albeit pretty slowly 
towards the end of the 20 minutes. However, the FLAC solutions 
substantially faster than the .WAV solution I was using.

Once I have my basic functionality complete and I am producing the 
output I desire, I am going to return and start working the efficiency 
issue. The model I am considering is using what Chris suggested on all 
files less than 8 seconds (rounding them to 8 seconds). And then 
appending all the files, substituting a over-sized files (greater than 8 
seconds) with 8 seconds of silence. And then I will then use &quot;pad&quot; on 
the remaining +8 second files. And then mix each of those into the 
master &quot;appended&quot; file. That seems like it will take the least amount of 
processing and file writing.


Jim


Mike Hirst wrote:
    &lt;/pre&gt;
    &lt;blockquote type=&quot;cite&quot;&gt;
      &lt;pre wrap=&quot;&quot;&gt;What is the maximum length of small file?

Jim O'Flaherty wrote:
  
      &lt;/pre&gt;
      &lt;blockquote type=&quot;cite&quot;&gt;
        &lt;pre wrap=&quot;&quot;&gt;Hi,

I have a project where I am taking a series of small sound files (.wav) 
and attempting to combine them into a single .wav file. In a specific 
order and at every 8 second marker starting from 0, I need one of these 
small sound files to play until it completes (typically in less than 8 
seconds). And then on the next 8 second marker, another small sound file 
plays. I have 140 these spanning 20 minutes.

My first approach was to take each of the small sound files and prepend 
(using &quot;pad&quot;) a number of seconds to the file. However, by the time it 
got to the 40th file, what was a small sound file before (~422K) was 
growing into the 10s of MB. I think this is because the output was a 
.wav and there is no compression in a .wav file. Here's an example 
Windows DOS command line entry:
%SOX% %PATH_SS%\024.wav %PATH_TEMP%\024_silence40.wav pad 304.000 norm

I am not stuck with .wav except as my input type. I want to experiment 
with using .flac. However, apparently some optional library is required. 
And, I have looked all over the SOX site and have not been able to 
figure out what that library might be, where to find it and what to do 
with it once I found it. I then went to the FLAC site. That was no help 
as there were no SOX references there.

So some questions:
  A) Is taking each of the 140 files and prepending it with (n * 8 
seconds of) silence (using the &quot;pad&quot; option) and then mixing the 140 
tracks together the proper way to approach generating the desired output 
of 140 small samples each playing at an 8 second interval? And what 
other options in SOX might there be to achieving this same effect?
  B) How much will FLAC speed up the processing? Using .wav as my 
output, saving tracks with 320 second of silence was taking 10s of 
seconds due to the file being 10s of MB large.
  C) Where can I go to find out what to dl and where to place it 
regarding the FLAC library so that SOX can use it?


Thank you,

Jim


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19258408&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;


    
        &lt;/pre&gt;
      &lt;/blockquote&gt;
      &lt;pre wrap=&quot;&quot;&gt;  
      &lt;/pre&gt;
    &lt;/blockquote&gt;
    &lt;pre wrap=&quot;&quot;&gt;------------------------------------------------------------------------

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;


------------------------------------------------------------------------

_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19258408&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;
    &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;
  &lt;/pre&gt;
&lt;/blockquote&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19258408&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19258408.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19257556</id>
	<title>Re: soxmix won't work</title>
	<published>2008-09-01T09:37:34Z</published>
	<updated>2008-09-01T09:37:34Z</updated>
	<author>
		<name>Pascal Giard</name>
	</author>
	<content type="html">On Fri, Aug 29, 2008 at 8:33 PM, gabriel troisgros &amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257556&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;joelasecla@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&amp;gt; hi
&lt;br&gt;&amp;gt; i have Version 12.17.9 installed on a debian...
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; when issuing the following command: soxmix -S gia.mp3 jungle.mp3 test.wav
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; i have a final.wav created, but this file is not a mix of both files, it
&lt;br&gt;&amp;gt; &amp;quot;contains&amp;quot; only the second one...any clue ?
&lt;br&gt;&lt;br&gt;I doubt we want to try to debug such an old version...
&lt;br&gt;Could you update to at least version &amp;gt;= 14.x ?
&lt;br&gt;&lt;br&gt;-Pascal
&lt;br&gt;-- 
&lt;br&gt;Homepage (&lt;a href=&quot;http://organact.mine.nu&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://organact.mine.nu&lt;/a&gt;)
&lt;br&gt;Debian GNU/Linux (&lt;a href=&quot;http://www.debian.org&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.debian.org&lt;/a&gt;)
&lt;br&gt;LACIME: École de technologie supérieure (&lt;a href=&quot;http://lacime.etsmtl.ca&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://lacime.etsmtl.ca&lt;/a&gt;)
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257556&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/soxmix-won%27t-work-tp19245516p19257556.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19257217</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-09-01T09:09:05Z</published>
	<updated>2008-09-01T09:09:05Z</updated>
	<author>
		<name>Mike Hirst</name>
	</author>
	<content type="html">Jim,
&lt;br&gt;&lt;br&gt;If all short files were less than 8 secs, it would be easy to add 
&lt;br&gt;silence to each short file to make 8 secs and then join them together. 
&lt;br&gt;The problem here is that some files are longer than 8 secs. They are, 
&lt;br&gt;however, shorter than 16 secs. Here's my suggestion.
&lt;br&gt;&lt;br&gt;1. Make two short files. One of 16 secs silence and the other 8 secs 
&lt;br&gt;silence.
&lt;br&gt;&lt;br&gt;2. concat the 16 secs file to the end of each of the short files (clips).
&lt;br&gt;&lt;br&gt;clip................
&lt;br&gt;longclip................
&lt;br&gt;verylongclip................
&lt;br&gt;etc
&lt;br&gt;&lt;br&gt;3. Trim the concatenated files (clips) to 16 secs
&lt;br&gt;&lt;br&gt;clip............
&lt;br&gt;longclip........
&lt;br&gt;verylongclip....
&lt;br&gt;etc
&lt;br&gt;&lt;br&gt;4. Concat half the trimmed 16 sec files Clips).
&lt;br&gt;&lt;br&gt;clip............longclip........verylongclip.... etc
&lt;br&gt;&lt;br&gt;5. Concat the 8 sec silence followed by the other half of the trimmed 16 
&lt;br&gt;sec files (clips).
&lt;br&gt;&lt;br&gt;........clip............longclip........verylongclip.... etc
&lt;br&gt;&lt;br&gt;6. Mix the two concatenated sequences.
&lt;br&gt;&lt;br&gt;clip............longclip........verylongclip....
&lt;br&gt;........clip............longclip........verylongclip.... etc
&lt;br&gt;&lt;br&gt;The result should be an audio clip starting every 8 secs. All clips play 
&lt;br&gt;for their full duration, with clips of over 8 secs continuing to play 
&lt;br&gt;after the start of the next 8 sec sequence.
&lt;br&gt;&lt;br&gt;Jim O'Flaherty wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Mike,
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Are you asking what the maximum length of the smallest file is? If so, 
&lt;br&gt;&amp;gt; it's 1.5 seconds. The files average around 6.75 seconds in length with 
&lt;br&gt;&amp;gt; no file being the same size as any other. However, the valley is 1.5 
&lt;br&gt;&amp;gt; seconds and the peak is 10.2 seconds. And neither the peaks nor valleys 
&lt;br&gt;&amp;gt; are uniform.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; BTW, I have since gotten FLAC to work as it is available without having 
&lt;br&gt;&amp;gt; to provide a library in the standard windows distribution. So, my 
&lt;br&gt;&amp;gt; initial technique described in A is working, albeit pretty slowly 
&lt;br&gt;&amp;gt; towards the end of the 20 minutes. However, the FLAC solutions 
&lt;br&gt;&amp;gt; substantially faster than the .WAV solution I was using.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Once I have my basic functionality complete and I am producing the 
&lt;br&gt;&amp;gt; output I desire, I am going to return and start working the efficiency 
&lt;br&gt;&amp;gt; issue. The model I am considering is using what Chris suggested on all 
&lt;br&gt;&amp;gt; files less than 8 seconds (rounding them to 8 seconds). And then 
&lt;br&gt;&amp;gt; appending all the files, substituting a over-sized files (greater than 8 
&lt;br&gt;&amp;gt; seconds) with 8 seconds of silence. And then I will then use &amp;quot;pad&amp;quot; on 
&lt;br&gt;&amp;gt; the remaining +8 second files. And then mix each of those into the 
&lt;br&gt;&amp;gt; master &amp;quot;appended&amp;quot; file. That seems like it will take the least amount of 
&lt;br&gt;&amp;gt; processing and file writing.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Jim
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Mike Hirst wrote:
&lt;br&gt;&amp;gt;&amp;gt; What is the maximum length of small file?
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; Jim O'Flaherty wrote:
&lt;br&gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Hi,
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I have a project where I am taking a series of small sound files (.wav) 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; and attempting to combine them into a single .wav file. In a specific 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; order and at every 8 second marker starting from 0, I need one of these 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; small sound files to play until it completes (typically in less than 8 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; seconds). And then on the next 8 second marker, another small sound file 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; plays. I have 140 these spanning 20 minutes.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; My first approach was to take each of the small sound files and prepend 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; (using &amp;quot;pad&amp;quot;) a number of seconds to the file. However, by the time it 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; got to the 40th file, what was a small sound file before (~422K) was 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; growing into the 10s of MB. I think this is because the output was a 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; .wav and there is no compression in a .wav file. Here's an example 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Windows DOS command line entry:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; %SOX% %PATH_SS%\024.wav %PATH_TEMP%\024_silence40.wav pad 304.000 norm
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; I am not stuck with .wav except as my input type. I want to experiment 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; with using .flac. However, apparently some optional library is required. 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; And, I have looked all over the SOX site and have not been able to 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; figure out what that library might be, where to find it and what to do 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; with it once I found it. I then went to the FLAC site. That was no help 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; as there were no SOX references there.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; So some questions:
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; A) Is taking each of the 140 files and prepending it with (n * 8 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; seconds of) silence (using the &amp;quot;pad&amp;quot; option) and then mixing the 140 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; tracks together the proper way to approach generating the desired output 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; of 140 small samples each playing at an 8 second interval? And what 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; other options in SOX might there be to achieving this same effect?
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; B) How much will FLAC speed up the processing? Using .wav as my 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; output, saving tracks with 320 second of silence was taking 10s of 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; seconds due to the file being 10s of MB large.
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; C) Where can I go to find out what to dl and where to place it 
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; regarding the FLAC library so that SOX can use it?
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Thank you,
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Jim
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257217&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt;&amp;gt; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&amp;gt;&amp;gt;
&lt;br&gt;&amp;gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ------------------------------------------------------------------------
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257217&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;Mike Hirst
&lt;br&gt;Managing Director
&lt;br&gt;DAS-360°
&lt;br&gt;16 Ocean View
&lt;br&gt;Whitley Bay
&lt;br&gt;Tyne &amp; Wear
&lt;br&gt;NE26 1AL
&lt;br&gt;&lt;br&gt;tel: 0191 289 3186
&lt;br&gt;email: &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257217&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mike.hirst@...&lt;/a&gt;
&lt;br&gt;web: &lt;a href=&quot;http://www.das360.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.das360.net&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19257217&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19257217.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19255761</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-09-01T07:36:23Z</published>
	<updated>2008-09-01T07:36:23Z</updated>
	<author>
		<name>Jim O'Flaherty</name>
	</author>
	<content type="html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
  &lt;title&gt;&lt;/title&gt;
&lt;/head&gt;
&lt;body bgcolor=&quot;#ffffff&quot; text=&quot;#000000&quot;&gt;
Mike,&lt;br&gt;
&lt;br&gt;
Are you asking what the maximum length of the smallest file is? If so,
it's 1.5 seconds. The files average around 6.75 seconds in length with
no file being the same size as any other. However, the valley is 1.5
seconds and the peak is 10.2 seconds. And neither the peaks nor valleys
are uniform.&lt;br&gt;
&lt;br&gt;
BTW, I have since gotten FLAC to work as it is available without having
to provide a library in the standard windows distribution. So, my
initial technique described in A is working, albeit pretty slowly
towards the end of the 20 minutes. However, the FLAC solutions
substantially faster than the .WAV solution I was using.&lt;br&gt;
&lt;br&gt;
Once I have my basic functionality complete and I am producing the
output I desire, I am going to return and start working the efficiency
issue. The model I am considering is using what Chris suggested on all
files less than 8 seconds (rounding them to 8 seconds). And then
appending all the files, substituting a over-sized files (greater than
8 seconds) with 8 seconds of silence. And then I will then use &quot;pad&quot; on
the remaining +8 second files. And then mix each of those into the
master &quot;appended&quot; file. That seems like it will take the least amount
of processing and file writing.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Mike Hirst wrote:
&lt;blockquote cite=&quot;mid:48BB891F.9080306@blueyonder.co.uk&quot; type=&quot;cite&quot;&gt;
  &lt;pre wrap=&quot;&quot;&gt;What is the maximum length of small file?

Jim O'Flaherty wrote:
  &lt;/pre&gt;
  &lt;blockquote type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;Hi,

I have a project where I am taking a series of small sound files (.wav) 
and attempting to combine them into a single .wav file. In a specific 
order and at every 8 second marker starting from 0, I need one of these 
small sound files to play until it completes (typically in less than 8 
seconds). And then on the next 8 second marker, another small sound file 
plays. I have 140 these spanning 20 minutes.

My first approach was to take each of the small sound files and prepend 
(using &quot;pad&quot;) a number of seconds to the file. However, by the time it 
got to the 40th file, what was a small sound file before (~422K) was 
growing into the 10s of MB. I think this is because the output was a 
.wav and there is no compression in a .wav file. Here's an example 
Windows DOS command line entry:
%SOX% %PATH_SS%\024.wav %PATH_TEMP%\024_silence40.wav pad 304.000 norm

I am not stuck with .wav except as my input type. I want to experiment 
with using .flac. However, apparently some optional library is required. 
And, I have looked all over the SOX site and have not been able to 
figure out what that library might be, where to find it and what to do 
with it once I found it. I then went to the FLAC site. That was no help 
as there were no SOX references there.

So some questions:
  A) Is taking each of the 140 files and prepending it with (n * 8 
seconds of) silence (using the &quot;pad&quot; option) and then mixing the 140 
tracks together the proper way to approach generating the desired output 
of 140 small samples each playing at an 8 second interval? And what 
other options in SOX might there be to achieving this same effect?
  B) How much will FLAC speed up the processing? Using .wav as my 
output, saving tracks with 320 second of silence was taking 10s of 
seconds due to the file being 10s of MB large.
  C) Where can I go to find out what to dl and where to place it 
regarding the FLAC library so that SOX can use it?


Thank you,

Jim


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19255761&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;


    &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;
  &lt;/pre&gt;
&lt;/blockquote&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19255761&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19255761.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19249422</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T23:18:07Z</published>
	<updated>2008-08-31T23:18:07Z</updated>
	<author>
		<name>Mike Hirst</name>
	</author>
	<content type="html">What is the maximum length of small file?
&lt;br&gt;&lt;br&gt;Jim O'Flaherty wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Hi,
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I have a project where I am taking a series of small sound files (.wav) 
&lt;br&gt;&amp;gt; and attempting to combine them into a single .wav file. In a specific 
&lt;br&gt;&amp;gt; order and at every 8 second marker starting from 0, I need one of these 
&lt;br&gt;&amp;gt; small sound files to play until it completes (typically in less than 8 
&lt;br&gt;&amp;gt; seconds). And then on the next 8 second marker, another small sound file 
&lt;br&gt;&amp;gt; plays. I have 140 these spanning 20 minutes.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; My first approach was to take each of the small sound files and prepend 
&lt;br&gt;&amp;gt; (using &amp;quot;pad&amp;quot;) a number of seconds to the file. However, by the time it 
&lt;br&gt;&amp;gt; got to the 40th file, what was a small sound file before (~422K) was 
&lt;br&gt;&amp;gt; growing into the 10s of MB. I think this is because the output was a 
&lt;br&gt;&amp;gt; .wav and there is no compression in a .wav file. Here's an example 
&lt;br&gt;&amp;gt; Windows DOS command line entry:
&lt;br&gt;&amp;gt; %SOX% %PATH_SS%\024.wav %PATH_TEMP%\024_silence40.wav pad 304.000 norm
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I am not stuck with .wav except as my input type. I want to experiment 
&lt;br&gt;&amp;gt; with using .flac. However, apparently some optional library is required. 
&lt;br&gt;&amp;gt; And, I have looked all over the SOX site and have not been able to 
&lt;br&gt;&amp;gt; figure out what that library might be, where to find it and what to do 
&lt;br&gt;&amp;gt; with it once I found it. I then went to the FLAC site. That was no help 
&lt;br&gt;&amp;gt; as there were no SOX references there.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; So some questions:
&lt;br&gt;&amp;gt; &amp;nbsp; A) Is taking each of the 140 files and prepending it with (n * 8 
&lt;br&gt;&amp;gt; seconds of) silence (using the &amp;quot;pad&amp;quot; option) and then mixing the 140 
&lt;br&gt;&amp;gt; tracks together the proper way to approach generating the desired output 
&lt;br&gt;&amp;gt; of 140 small samples each playing at an 8 second interval? And what 
&lt;br&gt;&amp;gt; other options in SOX might there be to achieving this same effect?
&lt;br&gt;&amp;gt; &amp;nbsp; B) How much will FLAC speed up the processing? Using .wav as my 
&lt;br&gt;&amp;gt; output, saving tracks with 320 second of silence was taking 10s of 
&lt;br&gt;&amp;gt; seconds due to the file being 10s of MB large.
&lt;br&gt;&amp;gt; &amp;nbsp; C) Where can I go to find out what to dl and where to place it 
&lt;br&gt;&amp;gt; regarding the FLAC library so that SOX can use it?
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Thank you,
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Jim
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt; This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;&amp;gt; Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;&amp;gt; Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;&amp;gt; _______________________________________________
&lt;br&gt;&amp;gt; Sox-users mailing list
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19249422&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&amp;gt; &lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; 
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;Mike Hirst
&lt;br&gt;Managing Director
&lt;br&gt;DAS-360°
&lt;br&gt;16 Ocean View
&lt;br&gt;Whitley Bay
&lt;br&gt;Tyne &amp; Wear
&lt;br&gt;NE26 1AL
&lt;br&gt;&lt;br&gt;tel: 0191 289 3186
&lt;br&gt;email: &lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19249422&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mike.hirst@...&lt;/a&gt;
&lt;br&gt;web: &lt;a href=&quot;http://www.das360.net&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.das360.net&lt;/a&gt;&lt;br&gt;&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19249422&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19249422.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19248330</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T20:01:25Z</published>
	<updated>2008-08-31T20:01:25Z</updated>
	<author>
		<name>Jim O'Flaherty</name>
	</author>
	<content type="html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
&lt;/head&gt;
&lt;body bgcolor=&quot;#ffffff&quot; text=&quot;#000000&quot;&gt;
Chris,&lt;br&gt;
&lt;br&gt;
On a lark, I decided to see if FLAC might be included by default
(without an external library) in the Windows sox.exe (non Cygwin) . And
it is. So, no extra .dll is required to fully use the FLAC support.&lt;br&gt;
&lt;br&gt;
Thank you again for your help.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim O'Flaherty wrote:
&lt;blockquote cite=&quot;mid:48BB07C1.9080501@yahoo.com&quot; type=&quot;cite&quot;&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
Chris,&lt;br&gt;
  &lt;br&gt;
I just read the very last paragraph of your reply again. Are you saying
that even the &quot;lame_enc.dll&quot; won't work (I had not validated it yet)?
And that the windows sox.exe does not recognize ANY external libraries?
If that is the case, then the main page might want to change the
comment indicating that &quot;(with optional external library)&quot; to &quot;(with
optional external library on non-windows systems)&quot;, or something
similar.&lt;br&gt;
  &lt;br&gt;
  &lt;br&gt;
Jim&lt;br&gt;
  &lt;br&gt;
  &lt;br&gt;
  &lt;br&gt;
Jim O'Flaherty wrote:
  &lt;blockquote cite=&quot;mid:48BB0602.4060603@yahoo.com&quot; type=&quot;cite&quot;&gt;
    &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
Chris,&lt;br&gt;
    &lt;br&gt;
Thank you very much for your reply.&lt;br&gt;
    &lt;br&gt;
I like your clever idea of attempting to round out each of the small
files to equal exactly 8 seconds. However, due to the nature of my
application, it will only work sporadically. Some of the files are
longer than 8 seconds and must overlap (mix) with the next one. A such,
I am trying to get to a uniform way to handle all the files. Making
special logic for files under 8 seconds and other logic for those over
8 seconds is quite a bit more work. I will do that if it comes down to
it is the only way to solve the problem without exploding files sizes
on my HD.&lt;br&gt;
    &lt;br&gt;
I am confused why the phrase &quot;(with optional external library)&quot; is used
on this page (&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;http://sox.sourceforge.net/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://sox.sourceforge.net/&lt;/a&gt;)
when listing FLAC (first
list, right column, 8th item down). It's making it appear similar to
how I got MP3s working, by placing the &quot;lame_enc.dll&quot; in the same
folder as the &quot;sox.exe&quot;. Is there a &quot;flac_enc.dll&quot; that's equivalent?&lt;br&gt;
    &lt;br&gt;
As to the speed increase using FLAC - the very slowest operation on my
computer is I/O. So, I am willing to use lots of processor time to do
lossless compression and then write out a much smaller file (way
smaller than the 10s of MB that the files begin to be towards the end
of my 20 minutes). As such, I figured that FLAC would maximize
throughput on my primary constraint, I/O. Once I get FLAC (or some
other lossless compression format) working, I will let you know what I
experience in terms of performance gain. It might be as you say, not
much.&lt;br&gt;
    &lt;br&gt;
I would rather not use Cygwin at this point. I have already invested a
number of hours in the current design. If I have to, I will. I sure
hope that adding FLAC is as simple as adding MP3 support was, just
adding a .dll to the sox.exe folder.&lt;br&gt;
    &lt;br&gt;
    &lt;br&gt;
Thank you,&lt;br&gt;
    &lt;br&gt;
Jim&lt;br&gt;
    &lt;br&gt;
    &lt;br&gt;
Chris Bagwell wrote:
    &lt;blockquote cite=&quot;mid:48BAAA42.8060000@cnpbagwell.com&quot; type=&quot;cite&quot;&gt;
      &lt;pre wrap=&quot;&quot;&gt;Jim O'Flaherty wrote:
  &lt;/pre&gt;
      &lt;blockquote type=&quot;cite&quot;&gt;
        &lt;pre wrap=&quot;&quot;&gt;So some questions:
  A) Is taking each of the 140 files and prepending it with (n * 8 
seconds of) silence (using the &quot;pad&quot; option) and then mixing the 140 
tracks together the proper way to approach generating the desired output 
of 140 small samples each playing at an 8 second interval? And what 
other options in SOX might there be to achieving this same effect?
  
    &lt;/pre&gt;
      &lt;/blockquote&gt;
      &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Sounds like your on the right track.  I have a small suggestion that 
will save some disk space.  If the majority are less then 8 seconds then 
use the soxi to find the exact length, do some script math to find how 
much to pad it out to 8 seconds and use pad to do that  Then use the 
--combine concatenate option on sox to concat as many exact 8 second 
files as possible together into a single file.  If they were all less 
then 8 seconds then you'd be able to do that with out the megs of 
padding at beginning.

Since I think you said they are not all 8 seconds, at least concat'ing 
all that you can into bigger files first will reduce the number 
intermediate files you need to concat with megs of silenece.
  &lt;/pre&gt;
      &lt;blockquote type=&quot;cite&quot;&gt;
        &lt;pre wrap=&quot;&quot;&gt;  B) How much will FLAC speed up the processing? Using .wav as my 
output, saving tracks with 320 second of silence was taking 10s of 
seconds due to the file being 10s of MB large.
  
    &lt;/pre&gt;
      &lt;/blockquote&gt;
      &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;I'm not sure that using FLAC will help with anything except disk space.
  &lt;/pre&gt;
      &lt;blockquote type=&quot;cite&quot;&gt;
        &lt;pre wrap=&quot;&quot;&gt;  C) Where can I go to find out what to dl and where to place it 
regarding the FLAC library so that SOX can use it?


  
    &lt;/pre&gt;
      &lt;/blockquote&gt;
      &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Your using windows, right?   The cygwin version of sox on download page 
contains FLAC support so you may give it a try.  It may have a file 
pathname issues in your script since cygwin emulates POSIX environment.

SoX under windows doesn't support dynamic detecting of DLL's so not much 
you could do expect recompile using mingw or VC++ to add in FLAC 
support.  Thats not been done as far as I know before.

Chris

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19248330&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;

  &lt;/pre&gt;
    &lt;/blockquote&gt;
    &lt;pre wrap=&quot;&quot;&gt;&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;&lt;/pre&gt;
    &lt;pre wrap=&quot;&quot;&gt;&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19248330&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;
  &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;
&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;&lt;/pre&gt;
  &lt;pre wrap=&quot;&quot;&gt;
&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19248330&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;
  &lt;/pre&gt;
&lt;/blockquote&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19248330&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19248330.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19246125</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T14:06:09Z</published>
	<updated>2008-08-31T14:06:09Z</updated>
	<author>
		<name>Jim O'Flaherty</name>
	</author>
	<content type="html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
&lt;/head&gt;
&lt;body bgcolor=&quot;#ffffff&quot; text=&quot;#000000&quot;&gt;
Chris,&lt;br&gt;
&lt;br&gt;
I just read the very last paragraph of your reply again. Are you saying
that even the &quot;lame_enc.dll&quot; won't work (I had not validated it yet)?
And that the windows sox.exe does not recognize ANY external libraries?
If that is the case, then the main page might want to change the
comment indicating that &quot;(with optional external library)&quot; to &quot;(with
optional external library on non-windows systems)&quot;, or something
similar.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Jim O'Flaherty wrote:
&lt;blockquote cite=&quot;mid:48BB0602.4060603@yahoo.com&quot; type=&quot;cite&quot;&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
Chris,&lt;br&gt;
  &lt;br&gt;
Thank you very much for your reply.&lt;br&gt;
  &lt;br&gt;
I like your clever idea of attempting to round out each of the small
files to equal exactly 8 seconds. However, due to the nature of my
application, it will only work sporadically. Some of the files are
longer than 8 seconds and must overlap (mix) with the next one. A such,
I am trying to get to a uniform way to handle all the files. Making
special logic for files under 8 seconds and other logic for those over
8 seconds is quite a bit more work. I will do that if it comes down to
it is the only way to solve the problem without exploding files sizes
on my HD.&lt;br&gt;
  &lt;br&gt;
I am confused why the phrase &quot;(with optional external library)&quot; is used
on this page (&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;http://sox.sourceforge.net/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://sox.sourceforge.net/&lt;/a&gt;)
when listing FLAC (first
list, right column, 8th item down). It's making it appear similar to
how I got MP3s working, by placing the &quot;lame_enc.dll&quot; in the same
folder as the &quot;sox.exe&quot;. Is there a &quot;flac_enc.dll&quot; that's equivalent?&lt;br&gt;
  &lt;br&gt;
As to the speed increase using FLAC - the very slowest operation on my
computer is I/O. So, I am willing to use lots of processor time to do
lossless compression and then write out a much smaller file (way
smaller than the 10s of MB that the files begin to be towards the end
of my 20 minutes). As such, I figured that FLAC would maximize
throughput on my primary constraint, I/O. Once I get FLAC (or some
other lossless compression format) working, I will let you know what I
experience in terms of performance gain. It might be as you say, not
much.&lt;br&gt;
  &lt;br&gt;
I would rather not use Cygwin at this point. I have already invested a
number of hours in the current design. If I have to, I will. I sure
hope that adding FLAC is as simple as adding MP3 support was, just
adding a .dll to the sox.exe folder.&lt;br&gt;
  &lt;br&gt;
  &lt;br&gt;
Thank you,&lt;br&gt;
  &lt;br&gt;
Jim&lt;br&gt;
  &lt;br&gt;
  &lt;br&gt;
Chris Bagwell wrote:
  &lt;blockquote cite=&quot;mid:48BAAA42.8060000@cnpbagwell.com&quot; type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;Jim O'Flaherty wrote:
  &lt;/pre&gt;
    &lt;blockquote type=&quot;cite&quot;&gt;
      &lt;pre wrap=&quot;&quot;&gt;So some questions:
  A) Is taking each of the 140 files and prepending it with (n * 8 
seconds of) silence (using the &quot;pad&quot; option) and then mixing the 140 
tracks together the proper way to approach generating the desired output 
of 140 small samples each playing at an 8 second interval? And what 
other options in SOX might there be to achieving this same effect?
  
    &lt;/pre&gt;
    &lt;/blockquote&gt;
    &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Sounds like your on the right track.  I have a small suggestion that 
will save some disk space.  If the majority are less then 8 seconds then 
use the soxi to find the exact length, do some script math to find how 
much to pad it out to 8 seconds and use pad to do that  Then use the 
--combine concatenate option on sox to concat as many exact 8 second 
files as possible together into a single file.  If they were all less 
then 8 seconds then you'd be able to do that with out the megs of 
padding at beginning.

Since I think you said they are not all 8 seconds, at least concat'ing 
all that you can into bigger files first will reduce the number 
intermediate files you need to concat with megs of silenece.
  &lt;/pre&gt;
    &lt;blockquote type=&quot;cite&quot;&gt;
      &lt;pre wrap=&quot;&quot;&gt;  B) How much will FLAC speed up the processing? Using .wav as my 
output, saving tracks with 320 second of silence was taking 10s of 
seconds due to the file being 10s of MB large.
  
    &lt;/pre&gt;
    &lt;/blockquote&gt;
    &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;I'm not sure that using FLAC will help with anything except disk space.
  &lt;/pre&gt;
    &lt;blockquote type=&quot;cite&quot;&gt;
      &lt;pre wrap=&quot;&quot;&gt;  C) Where can I go to find out what to dl and where to place it 
regarding the FLAC library so that SOX can use it?


  
    &lt;/pre&gt;
    &lt;/blockquote&gt;
    &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Your using windows, right?   The cygwin version of sox on download page 
contains FLAC support so you may give it a try.  It may have a file 
pathname issues in your script since cygwin emulates POSIX environment.

SoX under windows doesn't support dynamic detecting of DLL's so not much 
you could do expect recompile using mingw or VC++ to add in FLAC 
support.  Thats not been done as far as I know before.

Chris

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19246125&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a moz-do-not-send=&quot;true&quot; class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;

  &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;
&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;&lt;/pre&gt;
  &lt;pre wrap=&quot;&quot;&gt;
&lt;hr size=&quot;4&quot; width=&quot;90%&quot;&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19246125&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;
  &lt;/pre&gt;
&lt;/blockquote&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19246125&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19246125.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19246067</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T13:58:42Z</published>
	<updated>2008-08-31T13:58:42Z</updated>
	<author>
		<name>Jim O'Flaherty</name>
	</author>
	<content type="html">&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
&lt;html&gt;
&lt;head&gt;
  &lt;meta content=&quot;text/html;charset=ISO-8859-1&quot; http-equiv=&quot;Content-Type&quot;&gt;
&lt;/head&gt;
&lt;body bgcolor=&quot;#ffffff&quot; text=&quot;#000000&quot;&gt;
Chris,&lt;br&gt;
&lt;br&gt;
Thank you very much for your reply.&lt;br&gt;
&lt;br&gt;
I like your clever idea of attempting to round out each of the small
files to equal exactly 8 seconds. However, due to the nature of my
application, it will only work sporadically. Some of the files are
longer than 8 seconds and must overlap (mix) with the next one. A such,
I am trying to get to a uniform way to handle all the files. Making
special logic for files under 8 seconds and other logic for those over
8 seconds is quite a bit more work. I will do that if it comes down to
it is the only way to solve the problem without exploding files sizes
on my HD.&lt;br&gt;
&lt;br&gt;
I am confused why the phrase &quot;(with optional external library)&quot; is used
on this page (&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://sox.sourceforge.net/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://sox.sourceforge.net/&lt;/a&gt;) when listing FLAC (first
list, right column, 8th item down). It's making it appear similar to
how I got MP3s working, by placing the &quot;lame_enc.dll&quot; in the same
folder as the &quot;sox.exe&quot;. Is there a &quot;flac_enc.dll&quot; that's equivalent?&lt;br&gt;
&lt;br&gt;
As to the speed increase using FLAC - the very slowest operation on my
computer is I/O. So, I am willing to use lots of processor time to do
lossless compression and then write out a much smaller file (way
smaller than the 10s of MB that the files begin to be towards the end
of my 20 minutes). As such, I figured that FLAC would maximize
throughput on my primary constraint, I/O. Once I get FLAC (or some
other lossless compression format) working, I will let you know what I
experience in terms of performance gain. It might be as you say, not
much.&lt;br&gt;
&lt;br&gt;
I would rather not use Cygwin at this point. I have already invested a
number of hours in the current design. If I have to, I will. I sure
hope that adding FLAC is as simple as adding MP3 support was, just
adding a .dll to the sox.exe folder.&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Thank you,&lt;br&gt;
&lt;br&gt;
Jim&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
Chris Bagwell wrote:
&lt;blockquote cite=&quot;mid:48BAAA42.8060000@cnpbagwell.com&quot; type=&quot;cite&quot;&gt;
  &lt;pre wrap=&quot;&quot;&gt;Jim O'Flaherty wrote:
  &lt;/pre&gt;
  &lt;blockquote type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;So some questions:
  A) Is taking each of the 140 files and prepending it with (n * 8 
seconds of) silence (using the &quot;pad&quot; option) and then mixing the 140 
tracks together the proper way to approach generating the desired output 
of 140 small samples each playing at an 8 second interval? And what 
other options in SOX might there be to achieving this same effect?
  
    &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Sounds like your on the right track.  I have a small suggestion that 
will save some disk space.  If the majority are less then 8 seconds then 
use the soxi to find the exact length, do some script math to find how 
much to pad it out to 8 seconds and use pad to do that  Then use the 
--combine concatenate option on sox to concat as many exact 8 second 
files as possible together into a single file.  If they were all less 
then 8 seconds then you'd be able to do that with out the megs of 
padding at beginning.

Since I think you said they are not all 8 seconds, at least concat'ing 
all that you can into bigger files first will reduce the number 
intermediate files you need to concat with megs of silenece.
  &lt;/pre&gt;
  &lt;blockquote type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;  B) How much will FLAC speed up the processing? Using .wav as my 
output, saving tracks with 320 second of silence was taking 10s of 
seconds due to the file being 10s of MB large.
  
    &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;I'm not sure that using FLAC will help with anything except disk space.
  &lt;/pre&gt;
  &lt;blockquote type=&quot;cite&quot;&gt;
    &lt;pre wrap=&quot;&quot;&gt;  C) Where can I go to find out what to dl and where to place it 
regarding the FLAC library so that SOX can use it?


  
    &lt;/pre&gt;
  &lt;/blockquote&gt;
  &lt;pre wrap=&quot;&quot;&gt;&lt;!----&gt;Your using windows, right?   The cygwin version of sox on download page 
contains FLAC support so you may give it a try.  It may have a file 
pathname issues in your script since cygwin emulates POSIX environment.

SoX under windows doesn't support dynamic detecting of DLL's so not much 
you could do expect recompile using mingw or VC++ to add in FLAC 
support.  Thats not been done as far as I know before.

Chris

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK &amp;amp; win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;amp;url=/&lt;/a&gt;
_______________________________________________
Sox-users mailing list
&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19246067&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;a class=&quot;moz-txt-link-freetext&quot; href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;

  &lt;/pre&gt;
&lt;/blockquote&gt;
&lt;/body&gt;
&lt;/html&gt;
&lt;br /&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br /&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19246067&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19246067.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19245415</id>
	<title>Re: stat</title>
	<published>2008-08-31T12:45:43Z</published>
	<updated>2008-08-31T12:45:43Z</updated>
	<author>
		<name>robs-5</name>
	</author>
	<content type="html">--- On Fri, 29/8/08, Mike Hirst &amp;lt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19245415&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mike.hirst@...&lt;/a&gt;&amp;gt; wrote:
&lt;br&gt;&lt;br&gt;&amp;gt; Where can I find an explanation of the terms...
&lt;br&gt;&lt;br&gt;Please see the updated docs at &lt;a href=&quot;http://sox.sourceforge.net/Docs/HomePage&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://sox.sourceforge.net/Docs/HomePage&lt;/a&gt;&lt;br&gt;&lt;br&gt;Cheers,
&lt;br&gt;Rob
&lt;br&gt;&lt;br&gt;&lt;br&gt;Send instant messages to your online friends &lt;a href=&quot;http://uk.messenger.yahoo.com&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://uk.messenger.yahoo.com&lt;/a&gt;&amp;nbsp;
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19245415&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/stat-tp19223488p19245415.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19242810</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T07:38:54Z</published>
	<updated>2008-08-31T07:38:54Z</updated>
	<author>
		<name>Michael Chapman-4</name>
	</author>
	<content type="html">On Sunday 31 August 2008 2:51 pm, you wrote:
&lt;br&gt;&amp;gt; Quick reply, as I'm not a Windows guru, and I hope you will get a better
&lt;br&gt;&amp;gt; reply(!).
&lt;br&gt;&lt;br&gt;OK, Chris posted at the same time.
&lt;br&gt;Trust his; rather than mine!!
&lt;br&gt;&lt;br&gt;Would just add, do watch volume when mixing.
&lt;br&gt;You do _not_ want SoX to halve the volume each time it mixes two files, as 
&lt;br&gt;your silence will mean there is no risk of clipping anyway.
&lt;br&gt;In the manual.
&lt;br&gt;&lt;br&gt;MC
&lt;br&gt;&lt;br&gt;-------------------------------------------------------------------------
&lt;br&gt;This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
&lt;br&gt;Build the coolest Linux based applications with Moblin SDK &amp; win great prizes
&lt;br&gt;Grand prize is a trip for two to an Open Source event anywhere in the world
&lt;br&gt;&lt;a href=&quot;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://moblin-contest.org/redirect.php?banner_id=100&amp;url=/&lt;/a&gt;&lt;br&gt;_______________________________________________
&lt;br&gt;Sox-users mailing list
&lt;br&gt;&lt;a href=&quot;http://www.nabble.com/user/SendEmail.jtp?type=post&amp;post=19242810&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;Sox-users@...&lt;/a&gt;
&lt;br&gt;&lt;a href=&quot;https://lists.sourceforge.net/lists/listinfo/sox-users&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://lists.sourceforge.net/lists/listinfo/sox-users&lt;/a&gt;&lt;br&gt;</content>
	<link rel="alternate" type="text/html" href="http://www.nabble.com/Attempting-to-mix-140-files...-tp19239252p19242810.html" />
</entry>

<entry>
	<id>tag:www.nabble.com,2006:post-19242736</id>
	<title>Re: Attempting to mix 140 files...</title>
	<published>2008-08-31T07:31:33Z</published>
	<updated>2008-08-31T07:31:33Z</updated>
	<author>
		<name>Michael Chapman-4</name>
	</author>
	<content type="html">&lt;br&gt;Hi
&lt;br&gt;&lt;br&gt;Quick reply, as I'm not a Windows guru, and I hope you will get a better 
&lt;br&gt;reply(!).
&lt;br&gt;&lt;br&gt;You are trying to generate 18min 40s of output (140*8 seconds)(?), which is 
&lt;br&gt;about a quarter to a third of a CD (as WAV) so about 200 MBytes.
&lt;br&gt;&lt;br&gt;If this is a 'one off' fair enough, if not you might be better writing a 
&lt;br&gt;script (and may find a bootable Linux DVD a lot easier ... in the end).
&lt;br&gt;&lt;br&gt;If you have the disc space why not continue till you have 200 Mbytes?
&lt;br&gt;&lt;br&gt;Presuming FLAC has a Windows version, just install that and do
&lt;br&gt;a conversion of final.wav to final.flac?
&lt;br&gt;(If FLAC is installed before SoX I suspect it just finds it and you could do 
&lt;br&gt;the conversion in SoX, but unless discspace is a problem then compressing the 
&lt;br&gt;'mix' 140 times (each stage) is just going to slow everything down!!)
&lt;br&gt;FLAC will give you an output of 30 to 50% of the original (see their site for 
&lt;br&gt;less 'if i remember aright' figures!). With lots of silence you should get a 
&lt;br&gt;better figure than the typical.
&lt;br&gt;&lt;br&gt;If you want smaller (about 10% of original) use Vorbis (as in Ogg-Vorbis) or 
&lt;br&gt;... MP3. (But it will be lossy, unlike FLAC).
&lt;br&gt;&lt;br&gt;If you save compression to the last step, then SoX as it is can do the hard 
&lt;br&gt;work.
&lt;br&gt;&lt;br&gt;If you want a GUI compression then try Audacity (just load your final.wav in 
&lt;br&gt;and export as flac or ogg or MP3) ---again you will need the relevant 
&lt;br&gt;libraries but the Audacity site should tell you.
&lt;br&gt;&lt;br&gt;The SoX build literature does tell you all about optional libraries. But my 
&lt;br&gt;suspicion is that on Windows you may have to install them first and then 
&lt;br&gt;re-install SoX.
&lt;br&gt;&lt;br&gt;As before, if this is not a 'one off', it would be worth getting everything 
&lt;br&gt;working, if not, the above may give you a quick/dirty work around.
&lt;br&gt;&lt;br&gt;Michael
&lt;br&gt;&lt;br&gt;BTW There is surely an easy way of padding each file to 8 seconds, then just 
&lt;br&gt;concatenating the lot, but if you have already padded them all why start 
&lt;br&gt;again? (Though the 14th mix is going to be of two 200 MB files !!)
&lt;br&gt;That way the 140 input files would only total about 200 MBytes. Your method 
&lt;br&gt;(if I understood) will need about 20 GBytes of input files, but presumably 
&lt;br&gt;you make mix and delete, then repeat?
&lt;br&g