Release 4.2.1 tarball

This commit is contained in:
Gary Scavone
2013-09-29 23:40:35 +02:00
committed by Stephen Sinclair
parent 11cf5faa0a
commit 21b93795e7
1041 changed files with 23984 additions and 16348 deletions

View File

@@ -8,79 +8,156 @@
<img src="princeton.gif"> &nbsp; <img src="ccrma.gif"> &nbsp; <img src="mcgill.gif"><P>
<a class="qindex" href="index.html">Home</a> &nbsp; <a class="qindex" href="information.html">Information</a> &nbsp; <a class="qindex" href="classes.html">Classes</a> &nbsp; <a class="qindex" href="download.html">Download</a> &nbsp; <a class="qindex" href="usage.html">Usage</a> &nbsp; <a class="qindex" href="maillist.html">Mail List</a> &nbsp; <a class="qindex" href="system.html">Requirements</a> &nbsp; <a class="qindex" href="links.html">Links</a> &nbsp; <a class="qindex" href="tutorial.html">Tutorial</a></CENTER>
<HR>
<!-- Generated by Doxygen 1.3.4 -->
<h1>WaveLoop Class Reference</h1><code>#include &lt;<a class="el" href="WaveLoop_8h-source.html">WaveLoop.h</a>&gt;</code>
<!-- Generated by Doxygen 1.4.4 -->
<h1>WaveLoop Class Reference</h1><!-- doxytag: class="WaveLoop" --><!-- doxytag: inherits="FileWvIn" --><code>#include &lt;<a class="el" href="WaveLoop_8h-source.html">WaveLoop.h</a>&gt;</code>
<p>
<p>Inheritance diagram for WaveLoop:
<p><center><img src="classWaveLoop.png" usemap="#WaveLoop_map" border="0" alt=""></center>
<map name="WaveLoop_map">
<area href="classFileWvIn.html" alt="FileWvIn" shape="rect" coords="0,112,72,136">
<area href="classWvIn.html" alt="WvIn" shape="rect" coords="0,56,72,80">
<area href="classStk.html" alt="Stk" shape="rect" coords="0,0,72,24">
</map>
<a href="classWaveLoop-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>
STK waveform oscillator class.
<p>
This class inherits from <a class="el" href="classWvIn.html">WvIn</a> and provides audio file looping functionality.<p>
WaveLoop supports multi-channel data in interleaved format. It is important to distinguish the <a class="el" href="classWvIn.html#a16">tick()</a> methods, which return samples produced by averaging across sample frames, from the <a class="el" href="classWaveLoop.html#a6">tickFrame()</a> methods, which return pointers to multi-channel sample frames. For single-channel data, these methods return equivalent values.<p>
by Perry R. Cook and Gary P. Scavone, 1995 - 2004.
This class inherits from <a class="el" href="classFileWvIn.html">FileWvIn</a> and provides audio file looping functionality. Any audio file that can be loaded by <a class="el" href="classFileRead.html">FileRead</a> can be looped using this class.<p>
WaveLoop supports multi-channel data. It is important to distinguish the <a class="el" href="classWvIn.html#a5">tick()</a> methods, which return samples produced by averaging across sample frames, from the <a class="el" href="classWvIn.html#a7">tickFrame()</a> methods, which return references or pointers to multi-channel sample frames.<p>
by Perry R. Cook and Gary P. Scavone, 1995 - 2005.
<p>
<p>
Definition at line <a class="el" href="WaveLoop_8h-source.html#l00026">26</a> of file <a class="el" href="WaveLoop_8h-source.html">WaveLoop.h</a>.<table border=0 cellpadding=0 cellspacing=0>
<table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan=2><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="anchor" name="a0" doxytag="WaveLoop::WaveLoop" ></a>
&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a0">WaveLoop</a> (std::string fileName, bool raw=false)</td></tr>
<tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a0"></a><!-- doxytag: member="WaveLoop::WaveLoop" ref="a0" args="(unsigned long chunkThreshold=1000000, unsigned long chunkSize=1024)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a0">WaveLoop</a> (unsigned long chunkThreshold=1000000, unsigned long chunkSize=1024)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Class constructor. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="anchor" name="a1" doxytag="WaveLoop::~WaveLoop" ></a>
virtual&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a1">~WaveLoop</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Default constructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a1"></a><!-- doxytag: member="WaveLoop::WaveLoop" ref="a1" args="(std::string fileName, bool raw=false, bool doNormalize=true, unsigned long chunkThreshold=1000000, unsigned long chunkSize=1024)" -->
&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a1">WaveLoop</a> (std::string fileName, bool raw=false, bool doNormalize=true, unsigned long chunkThreshold=1000000, unsigned long chunkSize=1024)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Class destructor. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a2">setFrequency</a> (StkFloat frequency)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Class constructor that opens a specified file. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a2"></a><!-- doxytag: member="WaveLoop::~WaveLoop" ref="a2" args="()" -->
virtual&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a2">~WaveLoop</a> ()</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the data interpolation rate based on a looping frequency. </em> <a href="#a2"></a><em><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="anchor" name="a3" doxytag="WaveLoop::addTime" ></a>
void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a3">addTime</a> (StkFloat time)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Class destructor. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a3">openFile</a> (std::string fileName, bool raw=false, bool doNormalize=true)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Increment the read pointer by <em>aTime</em> samples, modulo file size. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a4">addPhase</a> (StkFloat angle)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Open the specified file and load its data. <a href="#a3"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a4">setRate</a> (StkFloat rate)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Increment current read pointer by <em>anAngle</em>, relative to a looping frequency. </em> <a href="#a4"></a><em><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>void&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a5">addPhaseOffset</a> (StkFloat angle)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the data read rate in samples. The rate can be negative. <a href="#a4"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a5">setFrequency</a> (StkFloat frequency)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add a phase offset to the current read pointer. </em> <a href="#a5"></a><em><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="anchor" name="a6" doxytag="WaveLoop::tickFrame" ></a>
const StkFloat *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a6">tickFrame</a> (void)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Set the data interpolation rate based on a looping frequency. <a href="#a5"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="anchor" name="a6"></a><!-- doxytag: member="WaveLoop::addTime" ref="a6" args="(StkFloat time)" -->
void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a6">addTime</a> (StkFloat time)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Return a pointer to the next sample frame of data. <br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top>StkFloat *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a7">tickFrame</a> (StkFloat *frameVector, unsigned int frames)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Increment the read pointer by <em>time</em> samples, modulo file size. <br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a7">addPhase</a> (StkFloat angle)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Read out sample <em>frames</em> of data to <em>frameVector</em>. </em> <a href="#a7"></a><em><br><br></td></tr>
<tr><td class="memItemLeft" nowrap align=right valign=top><a class="el" href="classStkFrames.html">StkFrames</a> &amp;&nbsp;</td><td class="memItemRight" valign=bottom><a class="el" href="classWaveLoop.html#a8">tickFrame</a> (<a class="el" href="classStkFrames.html">StkFrames</a> &amp;frames)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Increment current read pointer by <em>angle</em>, relative to a looping frequency. <a href="#a7"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">void&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="classWaveLoop.html#a8">addPhaseOffset</a> (StkFloat angle)</td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Fill the <a class="el" href="classStkFrames.html">StkFrames</a> object with sample frames of data and return the same reference. </em> <a href="#a8"></a><em><br><br></td></tr>
<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Add a phase offset to the current read pointer. <a href="#a8"></a><br></td></tr>
</table>
<hr><h2>Member Function Documentation</h2>
<a class="anchor" name="a2" doxytag="WaveLoop::setFrequency" ></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<a class="anchor" name="a3"></a><!-- doxytag: member="WaveLoop::openFile" ref="a3" args="(std::string fileName, bool raw=false, bool doNormalize=true)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> void WaveLoop::setFrequency </td>
<td class="md" nowrap valign="top">void WaveLoop::openFile </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">std::string&nbsp;</td>
<td class="mdname" nowrap> <em>fileName</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>bool&nbsp;</td>
<td class="mdname" nowrap> <em>raw</em> = <code>false</code>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>bool&nbsp;</td>
<td class="mdname" nowrap> <em>doNormalize</em> = <code>true</code></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Open the specified file and load its data.
<p>
Data from a previously opened file will be overwritten by this function. An <a class="el" href="classStkError.html">StkError</a> will be thrown if the file is not found, its format is unknown, or a read error occurs. If the file data is to be loaded incrementally from disk and normalization is specified, a scaling will be applied with respect to fixed-point limits. If the data format is floating-point, no scaling is performed.
<p>
Reimplemented from <a class="el" href="classFileWvIn.html#a3">FileWvIn</a>. </td>
</tr>
</table>
<a class="anchor" name="a4"></a><!-- doxytag: member="WaveLoop::setRate" ref="a4" args="(StkFloat rate)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void WaveLoop::setRate </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">StkFloat&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>rate</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Set the data read rate in samples. The rate can be negative.
<p>
If the rate value is negative, the data is read in reverse order.
<p>
Reimplemented from <a class="el" href="classFileWvIn.html#a11">FileWvIn</a>. </td>
</tr>
</table>
<a class="anchor" name="a5"></a><!-- doxytag: member="WaveLoop::setFrequency" ref="a5" args="(StkFloat frequency)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top">void WaveLoop::setFrequency </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">StkFloat&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>frequency</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
@@ -90,28 +167,27 @@ const StkFloat *&nbsp;</td><td class="memItemRight" valign=bottom><a class="el"
<p>
Set the data interpolation rate based on a looping frequency.
<p>
This function determines the interpolation rate based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>aFrequency</em> value corresponds to file cycles per second. The frequency can be negative, in which case the loop is read in reverse order. </td>
This function determines the interpolation rate based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>frequency</em> value corresponds to file cycles per second. The frequency can be negative, in which case the loop is read in reverse order. </td>
</tr>
</table>
<a class="anchor" name="a4" doxytag="WaveLoop::addPhase" ></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<a class="anchor" name="a7"></a><!-- doxytag: member="WaveLoop::addPhase" ref="a7" args="(StkFloat angle)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> void WaveLoop::addPhase </td>
<td class="md" nowrap valign="top">void WaveLoop::addPhase </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">StkFloat&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>angle</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
@@ -119,30 +195,29 @@ This function determines the interpolation rate based on the file size and the c
<td>
<p>
Increment current read pointer by <em>anAngle</em>, relative to a looping frequency.
Increment current read pointer by <em>angle</em>, relative to a looping frequency.
<p>
This function increments the read pointer based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>anAngle</em> value is a multiple of file size. </td>
This function increments the read pointer based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>anAngle</em> value is a multiple of file size. </td>
</tr>
</table>
<a class="anchor" name="a5" doxytag="WaveLoop::addPhaseOffset" ></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<a class="anchor" name="a8"></a><!-- doxytag: member="WaveLoop::addPhaseOffset" ref="a8" args="(StkFloat angle)" --><p>
<table class="mdTable" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> void WaveLoop::addPhaseOffset </td>
<td class="md" nowrap valign="top">void WaveLoop::addPhaseOffset </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">StkFloat&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>angle</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
&nbsp;
@@ -152,82 +227,7 @@ This function increments the read pointer based on the file size and the current
<p>
Add a phase offset to the current read pointer.
<p>
This function determines a time offset based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>anAngle</em> value is a multiple of file size. </td>
</tr>
</table>
<a class="anchor" name="a7" doxytag="WaveLoop::tickFrame" ></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> StkFloat* WaveLoop::tickFrame </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top">StkFloat *&nbsp;</td>
<td class="mdname" nowrap> <em>frameVector</em>, </td>
</tr>
<tr>
<td></td>
<td></td>
<td class="md" nowrap>unsigned int&nbsp;</td>
<td class="mdname" nowrap> <em>frames</em></td>
</tr>
<tr>
<td></td>
<td class="md">)&nbsp;</td>
<td class="md" colspan="2"><code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Read out sample <em>frames</em> of data to <em>frameVector</em>.
<p>
An <a class="el" href="classStkError.html">StkError</a> will be thrown if a file is read incrementally and a read error occurs.
<p>
Reimplemented from <a class="el" href="classWvIn.html#a21">WvIn</a>. </td>
</tr>
</table>
<a class="anchor" name="a8" doxytag="WaveLoop::tickFrame" ></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"> <a class="el" href="classStkFrames.html">StkFrames</a>&amp; WaveLoop::tickFrame </td>
<td class="md" valign="top">(&nbsp;</td>
<td class="md" nowrap valign="top"><a class="el" href="classStkFrames.html">StkFrames</a> &amp;&nbsp;</td>
<td class="mdname1" valign="top" nowrap> <em>frames</em> </td>
<td class="md" valign="top">&nbsp;)&nbsp;</td>
<td class="md" nowrap><code> [virtual]</code></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing=5 cellpadding=0 border=0>
<tr>
<td>
&nbsp;
</td>
<td>
<p>
Fill the <a class="el" href="classStkFrames.html">StkFrames</a> object with sample frames of data and return the same reference.
<p>
An <a class="el" href="classStkError.html">StkError</a> will be thrown if a file is read incrementally and a read error occurs or there is an incompatability between the number of channels in the <a class="el" href="classRtWvIn.html">RtWvIn</a> object and that in the <a class="el" href="classStkFrames.html">StkFrames</a> object.
<p>
Reimplemented from <a class="el" href="classWvIn.html#a22">WvIn</a>. </td>
This function determines a time offset based on the file size and the current <a class="el" href="classStk.html#e0">Stk::sampleRate</a>. The <em>angle</em> value is a multiple of file size. </td>
</tr>
</table>
<hr>The documentation for this class was generated from the following file:<ul>
@@ -236,7 +236,7 @@ Reimplemented from <a class="el" href="classWvIn.html#a22">WvIn</a>. </td>
<table>
<tr><td><A HREF="http://ccrma.stanford.edu/software/stk/"><I>The Synthesis ToolKit in C++ (STK)</I></A></td></tr>
<tr><td>&copy;1995-2004 Perry R. Cook and Gary P. Scavone. All Rights Reserved.</td></tr>
<tr><td>&copy;1995-2005 Perry R. Cook and Gary P. Scavone. All Rights Reserved.</td></tr>
</table>
</BODY>