Sophie

Sophie

distrib > Fedora > 14 > x86_64 > media > os > by-pkgid > 9c481c872fb0ae0cbadccdc2f4a18ab6 > files > 148

libasync-devel-0.17.0-5.fc14.x86_64.rpm

<!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"/>
<title>Async: Async::AudioDecimator Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<!-- Generated by Doxygen 1.6.2-20100208 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li><a href="dirs.html"><span>Directories</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="annotated.html"><span>Class&nbsp;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&nbsp;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&nbsp;Members</span></a></li>
    </ul>
  </div>
  <div class="navpath"><a class="el" href="namespaceAsync.html">Async</a>::<a class="el" href="classAsync_1_1AudioDecimator.html">AudioDecimator</a>
  </div>
</div>
<div class="contents">
<h1>Async::AudioDecimator Class Reference</h1><!-- doxytag: class="Async::AudioDecimator" --><!-- doxytag: inherits="Async::AudioProcessor" -->
<p>Decimates a higher sample rate into a lower one.  
<a href="#_details">More...</a></p>

<p><code>#include &lt;<a class="el" href="AsyncAudioDecimator_8h_source.html">AsyncAudioDecimator.h</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for Async::AudioDecimator:</div>
<div class="dynsection">
 <div class="center">
  <img src="classAsync_1_1AudioDecimator.png" usemap="#Async::AudioDecimator_map" alt=""/>
  <map id="Async::AudioDecimator_map" name="Async::AudioDecimator_map">
<area href="classAsync_1_1AudioProcessor.html" alt="Async::AudioProcessor" shape="rect" coords="77,56,222,80"/>
<area href="classAsync_1_1AudioSink.html" alt="Async::AudioSink" shape="rect" coords="0,0,145,24"/>
<area href="classAsync_1_1AudioSource.html" alt="Async::AudioSource" shape="rect" coords="155,0,300,24"/>
</map>
 </div>
</div>

<p><a href="classAsync_1_1AudioDecimator-members.html">List of all members.</a></p>
<h2>Public Member Functions</h2>
<ul>
<li><a class="el" href="classAsync_1_1AudioDecimator.html#ad95976d79fb6f1dceb97af8687487483">AudioDecimator</a> (int decimation_factor, const float *filter_coeff, int taps)
<dl class="el"><dd class="mdescRight">Constructor.  <a href="#ad95976d79fb6f1dceb97af8687487483"></a><br/></dl><li><a class="el" href="classAsync_1_1AudioDecimator.html#a674083ea6d097ac84a139f493dc3f636">~AudioDecimator</a> (void)
<dl class="el"><dd class="mdescRight">Destructor.  <a href="#a674083ea6d097ac84a139f493dc3f636"></a><br/></dl></ul>
<h2>Protected Member Functions</h2>
<ul>
<li>virtual void <a class="el" href="classAsync_1_1AudioDecimator.html#aabfa2bd5cc4d9f77bea7066f5c7cf950">processSamples</a> (float *dest, const float *src, int count)
<dl class="el"><dd class="mdescRight">Process incoming samples and put them into the output buffer.  <a href="#aabfa2bd5cc4d9f77bea7066f5c7cf950"></a><br/></dl></ul>
<hr/><a name="_details"></a><h2>Detailed Description</h2>
<p>Decimates a higher sample rate into a lower one. </p>
<dl class="author"><dt><b>Author:</b></dt><dd>Tobias Blomberg / SM0SVX </dd></dl>
<dl class="date"><dt><b>Date:</b></dt><dd>2008-04-06</dd></dl>
<p>This audio pipe class will decimate an audio stream down to a lower sampling rate. Decimation is a process where the sampling rate is reduced by an integer factor. To reduce the rate a lowpass filter must first be applied. This filter is built into this component. However, the filter coefficients (FIR) must be calculated manually.</p>
<p>Use this web page to calculate the coefficients: <a href="http://www.dsptutor.freeuk.com/remez/RemezFIRFilterDesign.html">http://www.dsptutor.freeuk.com/remez/RemezFIRFilterDesign.html</a></p>
<p>This implementation is based on the multirate FAQ at dspguru.com: <a href="http://dspguru.com/info/faqs/mrfaq.htm">http://dspguru.com/info/faqs/mrfaq.htm</a> </p>

<p>Definition at line <a class="el" href="AsyncAudioDecimator_8h_source.html#l00116">116</a> of file <a class="el" href="AsyncAudioDecimator_8h_source.html">AsyncAudioDecimator.h</a>.</p>
<hr/><h2>Constructor &amp; Destructor Documentation</h2>
<a class="anchor" id="ad95976d79fb6f1dceb97af8687487483"></a><!-- doxytag: member="Async::AudioDecimator::AudioDecimator" ref="ad95976d79fb6f1dceb97af8687487483" args="(int decimation_factor, const float *filter_coeff, int taps)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Async::AudioDecimator::AudioDecimator </td>
          <td>(</td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>decimation_factor</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float *&nbsp;</td>
          <td class="paramname"> <em>filter_coeff</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>taps</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Constructor. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>decimation_factor</em>&nbsp;</td><td>The decimation factor </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>filter_coeff</em>&nbsp;</td><td>An array holding the filter coefficients </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>taps</em>&nbsp;</td><td>The numer of taps in the filter </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a674083ea6d097ac84a139f493dc3f636"></a><!-- doxytag: member="Async::AudioDecimator::~AudioDecimator" ref="a674083ea6d097ac84a139f493dc3f636" args="(void)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">Async::AudioDecimator::~AudioDecimator </td>
          <td>(</td>
          <td class="paramtype">void&nbsp;</td>
          <td class="paramname"></td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Destructor. </p>

</div>
</div>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="aabfa2bd5cc4d9f77bea7066f5c7cf950"></a><!-- doxytag: member="Async::AudioDecimator::processSamples" ref="aabfa2bd5cc4d9f77bea7066f5c7cf950" args="(float *dest, const float *src, int count)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">virtual void Async::AudioDecimator::processSamples </td>
          <td>(</td>
          <td class="paramtype">float *&nbsp;</td>
          <td class="paramname"> <em>dest</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const float *&nbsp;</td>
          <td class="paramname"> <em>src</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&nbsp;</td>
          <td class="paramname"> <em>count</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td><code> [protected, virtual]</code></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>Process incoming samples and put them into the output buffer. </p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>dest</em>&nbsp;</td><td>Destination buffer </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>src</em>&nbsp;</td><td>Source buffer </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>count</em>&nbsp;</td><td>Number of samples in the source buffer</td></tr>
  </table>
  </dd>
</dl>
<p>This function should be reimplemented by the inheriting class to do the actual processing of the incoming samples. All samples must be processed, otherwise they are lost and the output buffer will contain garbage. </p>

<p>Implements <a class="el" href="classAsync_1_1AudioProcessor.html#a2d7e4ec25a7bd6a9c5c20ae35c1adee3">Async::AudioProcessor</a>.</p>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="AsyncAudioDecimator_8h_source.html">AsyncAudioDecimator.h</a></li>
</ul>
</div>
<hr class="footer"/><address style="text-align: right;"><small>Generated by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.2-20100208 </small></address>
</body>
</html>