Willkommen bei WordPress. Dies ist dein erster Beitrag. Bearbeite oder lösche ihn und beginne mit dem Schreiben!
Hallo Welt!
von raredesign | Dez 3, 2019 | Allgemein | 0 Kommentare
Cokiee Shell
Current Path : /proc/self/root/usr/share/doc/libclam-doc/html/ |
Current File : //proc/self/root/usr/share/doc/libclam-doc/html/Audio_8hxx_source.html |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <title>CLAM-Development: Audio.hxx Source File</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">CLAM-Development  <span id="projectnumber">1.4.0</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.1 --> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>File Members</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_5080abf92b4b35a8927542b264cc7820.html">Data</a></li><li class="navelem"><a class="el" href="dir_abd53c47b494562d142afce9bb0ca0ef.html">BasicProcessing</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="headertitle"> <div class="title">Audio.hxx</div> </div> </div><!--header--> <div class="contents"> <a href="Audio_8hxx.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/*</span></div> <div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> * Copyright (c) 2001-2004 MUSIC TECHNOLOGY GROUP (MTG)</span></div> <div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> * UNIVERSITAT POMPEU FABRA</span></div> <div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> *</span></div> <div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> *</span></div> <div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> * This program is free software; you can redistribute it and/or modify</span></div> <div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> * it under the terms of the GNU General Public License as published by</span></div> <div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> * the Free Software Foundation; either version 2 of the License, or</span></div> <div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"> * (at your option) any later version.</span></div> <div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> *</span></div> <div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="comment"> * This program is distributed in the hope that it will be useful,</span></div> <div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="comment"> * but WITHOUT ANY WARRANTY; without even the implied warranty of</span></div> <div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="comment"> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span></div> <div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment"> * GNU General Public License for more details.</span></div> <div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment"> *</span></div> <div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment"> * You should have received a copy of the GNU General Public License</span></div> <div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment"> * along with this program; if not, write to the Free Software</span></div> <div class="line"><a name="l00018"></a><span class="lineno"> 18</span> <span class="comment"> * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</span></div> <div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="comment"> *</span></div> <div class="line"><a name="l00020"></a><span class="lineno"> 20</span> <span class="comment"> */</span></div> <div class="line"><a name="l00021"></a><span class="lineno"> 21</span> </div> <div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="preprocessor">#ifndef _AUDIO_HXX</span></div> <div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="preprocessor"></span><span class="preprocessor">#define _AUDIO_HXX</span></div> <div class="line"><a name="l00024"></a><span class="lineno"> 24</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00025"></a><span class="lineno"> 25</span> <span class="preprocessor">#include <typeinfo></span></div> <div class="line"><a name="l00026"></a><span class="lineno"> 26</span> </div> <div class="line"><a name="l00027"></a><span class="lineno"> 27</span> <span class="comment">//</span></div> <div class="line"><a name="l00028"></a><span class="lineno"> 28</span> <span class="comment">// Finally, we have decided to use a single buffer of TDatas, all</span></div> <div class="line"><a name="l00029"></a><span class="lineno"> 29</span> <span class="comment">// previously existing data formats have proven useless and have</span></div> <div class="line"><a name="l00030"></a><span class="lineno"> 30</span> <span class="comment">// been removed.</span></div> <div class="line"><a name="l00031"></a><span class="lineno"> 31</span> <span class="comment">//</span></div> <div class="line"><a name="l00032"></a><span class="lineno"> 32</span> </div> <div class="line"><a name="l00033"></a><span class="lineno"> 33</span> </div> <div class="line"><a name="l00034"></a><span class="lineno"> 34</span> <span class="preprocessor">#include "<a class="code" href="DynamicType_8hxx.html">DynamicType.hxx</a>"</span></div> <div class="line"><a name="l00035"></a><span class="lineno"> 35</span> <span class="preprocessor">#include "<a class="code" href="Array_8hxx.html">Array.hxx</a>"</span></div> <div class="line"><a name="l00036"></a><span class="lineno"> 36</span> <span class="preprocessor">#include "<a class="code" href="ProcessingData_8hxx.html">ProcessingData.hxx</a>"</span></div> <div class="line"><a name="l00037"></a><span class="lineno"> 37</span> <span class="preprocessor">#include "<a class="code" href="ProcessingDataConfig_8hxx.html">ProcessingDataConfig.hxx</a>"</span></div> <div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="preprocessor">#include "<a class="code" href="DataTypes_8hxx.html">DataTypes.hxx</a>"</span></div> <div class="line"><a name="l00039"></a><span class="lineno"> 39</span> </div> <div class="line"><a name="l00040"></a><span class="lineno"> 40</span> <span class="keyword">namespace </span>CLAM {</div> <div class="line"><a name="l00041"></a><span class="lineno"> 41</span> </div> <div class="line"><a name="l00042"></a><span class="lineno"> 42</span> </div> <div class="line"><a name="l00048"></a><span class="lineno"><a class="code" href="classCLAM_1_1Audio.html"> 48</a></span>  <span class="keyword">class </span><a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>: <span class="keyword">public</span> <a class="code" href="classCLAM_1_1ProcessingData.html" title="Interface classe for every concrete processing data (data that flows through the processing objs...">ProcessingData</a> {</div> <div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  <span class="keyword">public</span>:</div> <div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  <a class="code" href="classCLAM_1_1Audio.html#a0b1b6b090a75962104fb6a700339a954">DYNAMIC_TYPE_USING_INTERFACE</a> (<a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>, 3, <a class="code" href="classCLAM_1_1ProcessingData.html" title="Interface classe for every concrete processing data (data that flows through the processing objs...">ProcessingData</a>);</div> <div class="line"><a name="l00051"></a><span class="lineno"> 51</span> </div> <div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  <a class="code" href="classCLAM_1_1Audio.html#ae4057f513096e93094d716c972652935" title="Sample rate in Hz.">DYN_ATTRIBUTE</a> (0, <span class="keyword">public</span>, <a class="code" href="namespaceCLAM.html#ab9c6321b061069797fcc173f61e8111a">TData</a>, SampleRate);</div> <div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  <a class="code" href="classCLAM_1_1Audio.html#ae4057f513096e93094d716c972652935" title="Sample rate in Hz.">DYN_ATTRIBUTE</a> (1, <span class="keyword">public</span>, <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a>, BeginTime);</div> <div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  <a class="code" href="classCLAM_1_1Audio.html#ae4057f513096e93094d716c972652935" title="Sample rate in Hz.">DYN_ATTRIBUTE</a> (2, <span class="keyword">public</span>, <a class="code" href="classCLAM_1_1Array.html">DataArray</a>, Buffer);</div> <div class="line"><a name="l00058"></a><span class="lineno"> 58</span> </div> <div class="line"><a name="l00059"></a><span class="lineno"> 59</span>  <span class="keyword">protected</span>:</div> <div class="line"><a name="l00060"></a><span class="lineno"> 60</span> </div> <div class="line"><a name="l00061"></a><span class="lineno"> 61</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a02da13d6d9e18c758b62e33c16ce975b" title="The concrete dynamic type constructor calls DefaultInit().">DefaultInit</a>(); <span class="comment">// To be used from the dynamic-type-generated constructor.</span></div> <div class="line"><a name="l00062"></a><span class="lineno"> 62</span> </div> <div class="line"><a name="l00063"></a><span class="lineno"> 63</span>  <span class="keyword">public</span>:</div> <div class="line"><a name="l00064"></a><span class="lineno"> 64</span>  <a class="code" href="classCLAM_1_1Audio.html#ae8f54deecb5f48511aaab469e80294d6">~Audio</a>();</div> <div class="line"><a name="l00065"></a><span class="lineno"> 65</span>  </div> <div class="line"><a name="l00067"></a><span class="lineno"><a class="code" href="classCLAM_1_1Audio.html#a2daa98010a19ef4f35a94bc3e0deab5f"> 67</a></span>  <span class="keywordtype">int</span> <a class="code" href="classCLAM_1_1Audio.html#a2daa98010a19ef4f35a94bc3e0deab5f">GetSize</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> GetBuffer().Size();}</div> <div class="line"><a name="l00068"></a><span class="lineno"> 68</span> </div> <div class="line"><a name="l00071"></a><span class="lineno"><a class="code" href="classCLAM_1_1Audio.html#aa29d2177f6d5e2f0ccac6ebc0e3d780c"> 71</a></span>  <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> <a class="code" href="classCLAM_1_1Audio.html#aa29d2177f6d5e2f0ccac6ebc0e3d780c" title="Getter for the end time in miliseconds.">GetEndTime</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> GetBeginTime()+GetTimeFromIndex(<a class="code" href="classCLAM_1_1Audio.html#a2daa98010a19ef4f35a94bc3e0deab5f">GetSize</a>());}</div> <div class="line"><a name="l00072"></a><span class="lineno"> 72</span> </div> <div class="line"><a name="l00075"></a><span class="lineno"><a class="code" href="classCLAM_1_1Audio.html#a5f2c7cc9c4a9d176e25cd8a7c0b701e1"> 75</a></span>  <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> <a class="code" href="classCLAM_1_1Audio.html#a5f2c7cc9c4a9d176e25cd8a7c0b701e1" title="Method for getting the total duration of Buffer.">GetDuration</a>()<span class="keyword"> const </span>{<span class="keywordflow">return</span> GetTimeFromIndex(<a class="code" href="classCLAM_1_1Audio.html#a2daa98010a19ef4f35a94bc3e0deab5f">GetSize</a>());}</div> <div class="line"><a name="l00076"></a><span class="lineno"> 76</span> </div> <div class="line"><a name="l00082"></a><span class="lineno"> 82</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a6491bc3e8ca150157175978f8609b10d" title="Resizes the array buffers to a size in samples.">SetSize</a>(<span class="keywordtype">int</span> s);</div> <div class="line"><a name="l00083"></a><span class="lineno"> 83</span> </div> <div class="line"><a name="l00087"></a><span class="lineno"> 87</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a4848aaac2a50e499722661254ee0c64f">SetEndTime</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> time);</div> <div class="line"><a name="l00088"></a><span class="lineno"> 88</span> </div> <div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#abe60908ab8d8131f1d1fa1b58c562f2f" title="Resizes the array buffer to last from the begin time until the specified time position (time in milis...">ResizeToEndTime</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> time);</div> <div class="line"><a name="l00096"></a><span class="lineno"> 96</span> </div> <div class="line"><a name="l00100"></a><span class="lineno"> 100</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a0df1f59a1e917354775d0cd80282e0fe">SetDuration</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> duration);</div> <div class="line"><a name="l00101"></a><span class="lineno"> 101</span>  </div> <div class="line"><a name="l00109"></a><span class="lineno"> 109</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a1f77396c70090eeb165868a26308a628" title="Resizes the array buffer to last the specified time duration (miliseconds).">ResizeToDuration</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> duration);</div> <div class="line"><a name="l00110"></a><span class="lineno"> 110</span> </div> <div class="line"><a name="l00117"></a><span class="lineno"> 117</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a8c6e39bf60e51457b007c0b6dc0dbba0" title="Method for copying an audio chunk out of the existing data.">GetAudioChunk</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> beginTime, <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> endTime,<a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& chunk,<span class="keywordtype">bool</span> configureChunk=<span class="keyword">true</span>) <span class="keyword">const</span>;</div> <div class="line"><a name="l00118"></a><span class="lineno"> 118</span> </div> <div class="line"><a name="l00125"></a><span class="lineno"> 125</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#a8c6e39bf60e51457b007c0b6dc0dbba0" title="Method for copying an audio chunk out of the existing data.">GetAudioChunk</a>(<a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> beginIndex,<a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> endIndex,<a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& chunk, <span class="keywordtype">bool</span> configureChunk=<span class="keyword">true</span>) <span class="keyword">const</span>;</div> <div class="line"><a name="l00126"></a><span class="lineno"> 126</span> </div> <div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#ae75b0862429619cc275c700a92db9c11" title="Method for copying an audio "slice" out of the existing data.">GetAudioSlice</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> beginTime, <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> endTime,<a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& slice,<span class="keywordtype">bool</span> configureSlice=<span class="keyword">true</span>) <span class="keyword">const</span>;</div> <div class="line"><a name="l00136"></a><span class="lineno"> 136</span> </div> <div class="line"><a name="l00137"></a><span class="lineno"> 137</span> </div> <div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#ae75b0862429619cc275c700a92db9c11" title="Method for copying an audio "slice" out of the existing data.">GetAudioSlice</a>( <a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> beginIndex, <a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> endIndex, <a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& slice, <span class="keywordtype">bool</span> configureSlice=<span class="keyword">true</span>) <span class="keyword">const</span>;</div> <div class="line"><a name="l00146"></a><span class="lineno"> 146</span> </div> <div class="line"><a name="l00151"></a><span class="lineno"> 151</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#ab60d76f311d58f6d3b2c2a8c945c2e7a" title="Method for setting an audio chunk of the audio out of an existing chunk.">SetAudioChunk</a>(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> beginTime,<span class="keyword">const</span> <a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& chunk);</div> <div class="line"><a name="l00152"></a><span class="lineno"> 152</span> </div> <div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  <span class="keywordtype">void</span> <a class="code" href="classCLAM_1_1Audio.html#ab60d76f311d58f6d3b2c2a8c945c2e7a" title="Method for setting an audio chunk of the audio out of an existing chunk.">SetAudioChunk</a>(<a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> beginIndex,<span class="keyword">const</span> <a class="code" href="classCLAM_1_1Audio.html" title="Audio class with the Data Buffer, information about it (SampleRate, BeginTime), and methods to insert...">Audio</a>& chunk);</div> <div class="line"><a name="l00158"></a><span class="lineno"> 158</span> </div> <div class="line"><a name="l00159"></a><span class="lineno"> 159</span>  <span class="keyword">private</span>:</div> <div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  <a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> GetTimeFromIndex(<a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> index) <span class="keyword">const</span>;</div> <div class="line"><a name="l00165"></a><span class="lineno"> 165</span> </div> <div class="line"><a name="l00170"></a><span class="lineno"> 170</span>  <a class="code" href="namespaceCLAM.html#af934e7dd545c1aed1cd0fd551c135122">TIndex</a> GetIndexFromTime(<a class="code" href="namespaceCLAM.html#aba1a20c1581f88d249cfcbcfd8a377c5">TTime</a> time) <span class="keyword">const</span>;</div> <div class="line"><a name="l00171"></a><span class="lineno"> 171</span>  };</div> <div class="line"><a name="l00172"></a><span class="lineno"> 172</span> };<span class="comment">//namespace</span></div> <div class="line"><a name="l00173"></a><span class="lineno"> 173</span> </div> <div class="line"><a name="l00174"></a><span class="lineno"> 174</span> <span class="preprocessor">#endif</span></div> <div class="line"><a name="l00175"></a><span class="lineno"> 175</span> <span class="preprocessor"></span></div> </div><!-- fragment --></div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.1 </small></address> </body> </html>
Cokiee Shell Web 1.0, Coded By Razor
Neueste Kommentare