This commit is contained in:
2020-04-04 17:19:13 +02:00
parent 2cb0a7449a
commit f36bfab5aa
78 changed files with 4370 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
<html><head><meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"><title>Encoder options</title><link rel="stylesheet" href="ts3doc.css" type="text/css"><meta name="generator" content="DocBook XSL Stylesheets V1.74.0"><link rel="home" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="up" href="index.html" title="TeamSpeak 3 Client SDK Developer Manual"><link rel="prev" href="ar01s14.html" title="Sound codecs"><link rel="next" href="ar01s16.html" title="Preprocessor options"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><img id="logo" src="images/logo.png"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Encoder options</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="ar01s14.html"><img src="images/prev.png" alt="Prev"></a><EFBFBD></td><th width="60%" align="center"><EFBFBD></th><td width="20%" align="right"><EFBFBD><a accesskey="n" href="ar01s16.html"><img src="images/next.png" alt="Next"></a></td></tr></table><hr></div><div class="section" lang="en"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="encoder"></a>Encoder options</h2></div></div></div><p>Speech quality and bandwidth usage depend on the used Speex encoder. As Speex is a lossy code, the quality value controls the balance between voice quality and network traffic. Valid quality values range from 0 to 10, default is 7. The encoding quality can be configured for each channel using the <em class="structfield"><code>CHANNEL_CODEC_QUALITY</code></em> property. The currently used channel codec, codec quality and estimated average used bitrate (without overhead) can be queried with <code class="function">ts3client_getEncodeConfigValue</code>.</p><a class="indexterm" name="idm44835434459712"></a><div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="images/note.png"></td><th align="left">Note</th></tr><tr><td align="left" valign="top"><p>Encoder options are tied to a capture device, so querying the values only makes sense after a device has been opened.</p></td></tr></table></div><p>All strings passed from the Client Lib are encoded in UTF-8 format.</p><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0" class="funcprototype-table"><tr><td><code class="funcdef">unsigned int <b class="fsfunc">ts3client_getEncodeConfigValue</b>(</code></td><td><var class="pdparam">serverConnectionHandlerID</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">ident</var>, </td><td><EFBFBD></td></tr><tr><td><EFBFBD></td><td><var class="pdparam">result</var><code>)</code>;</td><td><EFBFBD></td></tr></table><div class="paramdef-list"><code>uint64 <var class="pdparam">serverConnectionHandlerID</var></code>;<br><code>const char* <var class="pdparam">ident</var></code>;<br><code>char** <var class="pdparam">result</var></code>;</div><div class="funcprototype-spacer"><EFBFBD></div></div><a class="indexterm" name="idm44835434454544"></a><div class="itemizedlist"><ul type="disc"><li><p><em class="parameter"><code>serverConnectionHandlerID</code></em></p><p>Server connection handler ID</p></li><li><p><em class="parameter"><code>ident</code></em></p><p>String containing the queried encoder option. Available values are &#8220;<span class="quote">name</span>&#8221;, &#8220;<span class="quote">quality</span>&#8221; and &#8220;<span class="quote">bitrate</span>&#8221;.</p></li><li><p><em class="parameter"><code>result</code></em></p><p>Address of a variable that receives the result string. Unless an error occured, the result string must be released using <a class="link" href="ar01s28.html#freememory"><code class="function">ts3client_freeMemory</code></a>.</p></li></ul></div><p>Returns <em class="structfield"><code>ERROR_ok</code></em> on success, otherwise an error code as defined in <code class="filename">public_errors.h</code>. If an error has occured, the result string is uninitialized and must not be released.</p><p>To adjust the channel codec quality to a value of 5, you would call:
</p><pre class="programlisting">ts3client_setChannelVariableAsInt(scHandlerID, channelID, CHANNEL_CODEC_QUALITY, 5);</pre><p>See the chapter about <a class="link" href="ar01s22s02.html" title="Channel information">channel information</a> for details about how to set channel variables.</p><p>To query information about the current channel quality, do:
</p><pre class="programlisting">char *name, *quality, *bitrate;
ts3client_getEncodeConfigValue(scHandlerID, "name", &amp;name);
ts3client_getEncodeConfigValue(scHandlerID, "quality", &amp;quality);
ts3client_getEncodeConfigValue(scHandlerID, "bitrate", &amp;bitrate);
printf("Name = %s, quality = %s, bitrate = %s\n", name, quality, bitrate);
ts3client_freeMemory(name);
ts3client_freeMemory(quality);
ts3client_freeMemory(bitrate);</pre><p>
</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="ar01s14.html"><img src="images/prev.png" alt="Prev"></a><EFBFBD></td><td width="20%" align="center"><EFBFBD></td><td width="40%" align="right"><EFBFBD><a accesskey="n" href="ar01s16.html"><img src="images/next.png" alt="Next"></a></td></tr><tr><td width="40%" align="left" valign="top">Sound codecs<63></td><td width="20%" align="center"><a accesskey="h" href="index.html"><img src="images/home.png" alt="Home"></a></td><td width="40%" align="right" valign="top"><EFBFBD>Preprocessor options</td></tr></table></div></body></html>