Sophie

Sophie

distrib > Mandriva > 2009.1 > x86_64 > media > main-testing > by-pkgid > 187676b5433787923dfa2cdd6900c6cd > files > 148

lib64pulseaudio-devel-0.9.15-2.0.7mdv2009.1.x86_64.rpm

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>PulseAudio: scache.h File 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.5.8 -->
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="main.html"><span>Main&nbsp;Page</span></a></li>
      <li><a href="pages.html"><span>Related&nbsp;Pages</span></a></li>
      <li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li><a href="examples.html"><span>Examples</span></a></li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="files.html"><span>File&nbsp;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div>
<div class="contents">
<h1>scache.h File Reference</h1>All sample cache related routines.  
<a href="#_details">More...</a>
<p>

<p>
<a href="scache_8h-source.html">Go to the source code of this file.</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Typedefs</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">typedef void(*&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#9843db9018ac9038c6acd3229bca4f0e">pa_context_play_sample_cb_t</a> )(<a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *c, uint32_t idx, void *userdata)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Callback prototype for <a class="el" href="scache_8h.html#4ac9ef460c5182e521dd90613bd7922c" title="Play a sample from the sample cache to the specified device, allowing specification...">pa_context_play_sample_with_proplist()</a>.  <a href="#9843db9018ac9038c6acd3229bca4f0e"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#4725d83c96ddb3a4c67954bf5ec3a8c1">pa_stream_connect_upload</a> (<a class="el" href="stream_8h.html#960d798980692a2ff01e5a70553d4f29">pa_stream</a> *s, size_t length)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Make this stream a sample upload stream.  <a href="#4725d83c96ddb3a4c67954bf5ec3a8c1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">int&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#892d5d35de5ec726b8fa151abd87b92b">pa_stream_finish_upload</a> (<a class="el" href="stream_8h.html#960d798980692a2ff01e5a70553d4f29">pa_stream</a> *s)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Finish the sample upload, the stream name will become the sample name.  <a href="#892d5d35de5ec726b8fa151abd87b92b"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#8c5e594fd912cd5badab7804eae22ba9">pa_context_remove_sample</a> (<a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *c, const char *name, <a class="el" href="context_8h.html#010aff61766ac2d9585d78a164c0fc9a">pa_context_success_cb_t</a> cb, void *userdata)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Remove a sample from the sample cache.  <a href="#8c5e594fd912cd5badab7804eae22ba9"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#db1bf81ecef03f8bae77e5e3ab30464f">pa_context_play_sample</a> (<a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *c, const char *name, const char *dev, <a class="el" href="volume_8h.html#6d671c65284ff2e94d3773c7368a0352">pa_volume_t</a> volume, <a class="el" href="context_8h.html#010aff61766ac2d9585d78a164c0fc9a">pa_context_success_cb_t</a> cb, void *userdata)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Play a sample from the sample cache to the specified device.  <a href="#db1bf81ecef03f8bae77e5e3ab30464f"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a> *&nbsp;</td><td class="memItemRight" valign="bottom"><a class="el" href="scache_8h.html#4ac9ef460c5182e521dd90613bd7922c">pa_context_play_sample_with_proplist</a> (<a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *c, const char *name, const char *dev, <a class="el" href="volume_8h.html#6d671c65284ff2e94d3773c7368a0352">pa_volume_t</a> volume, <a class="el" href="proplist_8h.html#cdf756a6014b6fae3b358b2c934c3426">pa_proplist</a> *proplist, <a class="el" href="scache_8h.html#9843db9018ac9038c6acd3229bca4f0e">pa_context_play_sample_cb_t</a> cb, void *userdata)</td></tr>

<tr><td class="mdescLeft">&nbsp;</td><td class="mdescRight">Play a sample from the sample cache to the specified device, allowing specification of a property list for the playback stream.  <a href="#4ac9ef460c5182e521dd90613bd7922c"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
All sample cache related routines. 
<p>
<hr><h2>Typedef Documentation</h2>
<a class="anchor" name="9843db9018ac9038c6acd3229bca4f0e"></a><!-- doxytag: member="scache.h::pa_context_play_sample_cb_t" ref="9843db9018ac9038c6acd3229bca4f0e" args=")(pa_context *c, uint32_t idx, void *userdata)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">typedef void(* <a class="el" href="scache_8h.html#9843db9018ac9038c6acd3229bca4f0e">pa_context_play_sample_cb_t</a>)(<a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *c, uint32_t idx, void *userdata)          </td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Callback prototype for <a class="el" href="scache_8h.html#4ac9ef460c5182e521dd90613bd7922c" title="Play a sample from the sample cache to the specified device, allowing specification...">pa_context_play_sample_with_proplist()</a>. 
<p>
The idx value is the index of the sink input object, or PA_INVALID_INDEX on failure. <dl class="since" compact><dt><b>Since:</b></dt><dd>0.9.11 </dd></dl>

</div>
</div><p>
<hr><h2>Function Documentation</h2>
<a class="anchor" name="db1bf81ecef03f8bae77e5e3ab30464f"></a><!-- doxytag: member="scache.h::pa_context_play_sample" ref="db1bf81ecef03f8bae77e5e3ab30464f" args="(pa_context *c, const char *name, const char *dev, pa_volume_t volume, pa_context_success_cb_t cb, void *userdata)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a>* pa_context_play_sample           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *&nbsp;</td>
          <td class="paramname"> <em>c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>dev</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="volume_8h.html#6d671c65284ff2e94d3773c7368a0352">pa_volume_t</a>&nbsp;</td>
          <td class="paramname"> <em>volume</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="context_8h.html#010aff61766ac2d9585d78a164c0fc9a">pa_context_success_cb_t</a>&nbsp;</td>
          <td class="paramname"> <em>cb</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&nbsp;</td>
          <td class="paramname"> <em>userdata</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Play a sample from the sample cache to the specified device. 
<p>
If the latter is NULL use the default sink. Returns an operation object <dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>c</em>&nbsp;</td><td>Context </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>Name of the sample to play </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>dev</em>&nbsp;</td><td>Sink to play this sample on </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>volume</em>&nbsp;</td><td>Volume to play this sample with. Starting with 0.9.15 you may pass here (pa_volume_t) -1 which will leave the decision about the volume to the server side which is a good idea. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cb</em>&nbsp;</td><td>Call this function after successfully starting playback, or NULL </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>userdata</em>&nbsp;</td><td>Userdata to pass to the callback </td></tr>
  </table>
</dl>

</div>
</div><p>
<a class="anchor" name="4ac9ef460c5182e521dd90613bd7922c"></a><!-- doxytag: member="scache.h::pa_context_play_sample_with_proplist" ref="4ac9ef460c5182e521dd90613bd7922c" args="(pa_context *c, const char *name, const char *dev, pa_volume_t volume, pa_proplist *proplist, pa_context_play_sample_cb_t cb, void *userdata)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a>* pa_context_play_sample_with_proplist           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *&nbsp;</td>
          <td class="paramname"> <em>c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>dev</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="volume_8h.html#6d671c65284ff2e94d3773c7368a0352">pa_volume_t</a>&nbsp;</td>
          <td class="paramname"> <em>volume</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="proplist_8h.html#cdf756a6014b6fae3b358b2c934c3426">pa_proplist</a> *&nbsp;</td>
          <td class="paramname"> <em>proplist</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="scache_8h.html#9843db9018ac9038c6acd3229bca4f0e">pa_context_play_sample_cb_t</a>&nbsp;</td>
          <td class="paramname"> <em>cb</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&nbsp;</td>
          <td class="paramname"> <em>userdata</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Play a sample from the sample cache to the specified device, allowing specification of a property list for the playback stream. 
<p>
If the latter is NULL use the default sink. Returns an operation object. <dl class="since" compact><dt><b>Since:</b></dt><dd>0.9.11 </dd></dl>
<dl compact><dt><b>Parameters:</b></dt><dd>
  <table border="0" cellspacing="2" cellpadding="0">
    <tr><td valign="top"></td><td valign="top"><em>c</em>&nbsp;</td><td>Context </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>name</em>&nbsp;</td><td>Name of the sample to play </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>dev</em>&nbsp;</td><td>Sink to play this sample on </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>volume</em>&nbsp;</td><td>Volume to play this sample with. Starting with 0.9.15 you may pass here (pa_volume_t) -1 which will leave the decision about the volume to the server side which is a good idea. </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>proplist</em>&nbsp;</td><td>Property list for this sound. The property list of the cached entry will be merged into this property list </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>cb</em>&nbsp;</td><td>Call this function after successfully starting playback, or NULL </td></tr>
    <tr><td valign="top"></td><td valign="top"><em>userdata</em>&nbsp;</td><td>Userdata to pass to the callback </td></tr>
  </table>
</dl>

</div>
</div><p>
<a class="anchor" name="8c5e594fd912cd5badab7804eae22ba9"></a><!-- doxytag: member="scache.h::pa_context_remove_sample" ref="8c5e594fd912cd5badab7804eae22ba9" args="(pa_context *c, const char *name, pa_context_success_cb_t cb, void *userdata)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname"><a class="el" href="operation_8h.html#5614a07f2e7a129e4cb16596ed452a0c">pa_operation</a>* pa_context_remove_sample           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="context_8h.html#ff56e9b3dd442a88227da084bb5c380a">pa_context</a> *&nbsp;</td>
          <td class="paramname"> <em>c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&nbsp;</td>
          <td class="paramname"> <em>name</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="context_8h.html#010aff61766ac2d9585d78a164c0fc9a">pa_context_success_cb_t</a>&nbsp;</td>
          <td class="paramname"> <em>cb</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">void *&nbsp;</td>
          <td class="paramname"> <em>userdata</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Remove a sample from the sample cache. 
<p>
Returns an operation object which may be used to cancel the operation while it is running 
</div>
</div><p>
<a class="anchor" name="4725d83c96ddb3a4c67954bf5ec3a8c1"></a><!-- doxytag: member="scache.h::pa_stream_connect_upload" ref="4725d83c96ddb3a4c67954bf5ec3a8c1" args="(pa_stream *s, size_t length)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int pa_stream_connect_upload           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="stream_8h.html#960d798980692a2ff01e5a70553d4f29">pa_stream</a> *&nbsp;</td>
          <td class="paramname"> <em>s</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">size_t&nbsp;</td>
          <td class="paramname"> <em>length</em></td><td>&nbsp;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Make this stream a sample upload stream. 
<p>

</div>
</div><p>
<a class="anchor" name="892d5d35de5ec726b8fa151abd87b92b"></a><!-- doxytag: member="scache.h::pa_stream_finish_upload" ref="892d5d35de5ec726b8fa151abd87b92b" args="(pa_stream *s)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">int pa_stream_finish_upload           </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="stream_8h.html#960d798980692a2ff01e5a70553d4f29">pa_stream</a> *&nbsp;</td>
          <td class="paramname"> <em>s</em>          </td>
          <td>&nbsp;)&nbsp;</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">

<p>
Finish the sample upload, the stream name will become the sample name. 
<p>
You cancel a sample upload by issuing <a class="el" href="stream_8h.html#a4e0c83264f3935911e6b30e6f8ef2b1" title="Disconnect a stream from a source/sink.">pa_stream_disconnect()</a> 
</div>
</div><p>
</div>
<hr size="1"><address style="text-align: right;"><small>Generated on Wed Sep 2 04:18:20 2009 for PulseAudio by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>