1 | <html> |
---|
2 | |
---|
3 | <head> |
---|
4 | <title>libvorbisenc - function - vorbis_encode_setup_vbr</title> |
---|
5 | <link rel=stylesheet href="style.css" type="text/css"> |
---|
6 | </head> |
---|
7 | |
---|
8 | <body bgcolor=white text=black link="#5555ff" alink="#5555ff" vlink="#5555ff"> |
---|
9 | <table border=0 width=100%> |
---|
10 | <tr> |
---|
11 | <td><p class=tiny>libvorbisenc documentation</p></td> |
---|
12 | <td align=right><p class=tiny>libvorbisenc release 1.1 - 20040709</p></td> |
---|
13 | </tr> |
---|
14 | </table> |
---|
15 | |
---|
16 | <h1>vorbis_encode_setup_vbr</h1> |
---|
17 | |
---|
18 | <p><i>declared in "vorbis/libvorbisenc.h";</i></p> |
---|
19 | |
---|
20 | <p>This function performs step-one of a three-step variable bitrate |
---|
21 | (quality-based) encode setup. It functions similarly to the one-step |
---|
22 | setup performed by <a |
---|
23 | href="vorbis_encode_init_vbr.html">vorbis_encode_init_vbr()</a> but |
---|
24 | allows an application to make further encode setup tweaks using <a |
---|
25 | href="vorbis_encode_ctl.html">vorbis_encode_ctl()</a> before finally |
---|
26 | calling <a |
---|
27 | href="vorbis_encode_setup_init.html">vorbis_encode_setup_init()</a> to |
---|
28 | complete the setup process. |
---|
29 | |
---|
30 | <p>Before this function is called, the <a href="vorbis_info.html">vorbis_info</a> struct should be initialized by using vorbis_info_init() from the libvorbis API. After encoding, vorbis_info_clear should be called. |
---|
31 | <p> |
---|
32 | <br><br> |
---|
33 | <table border=0 color=black cellspacing=0 cellpadding=7> |
---|
34 | <tr bgcolor=#cccccc> |
---|
35 | <td> |
---|
36 | <pre><b> |
---|
37 | extern int vorbis_encode_init_vbr(<a href="vorbis_info.html">vorbis_info</a> *vi, |
---|
38 | long channels, |
---|
39 | long rate, |
---|
40 | |
---|
41 | float base_quality); |
---|
42 | |
---|
43 | </b></pre> |
---|
44 | </td> |
---|
45 | </tr> |
---|
46 | </table> |
---|
47 | |
---|
48 | <h3>Parameters</h3> |
---|
49 | <dl> |
---|
50 | <dt><i>vi</i></dt> |
---|
51 | <dd>File pointer to an initialized <a href="vorbis_info.html">vorbis_info</a> struct.</dd> |
---|
52 | <dt><i>channels</i></dt> |
---|
53 | <dd>The number of channels to be encoded.</dd> |
---|
54 | <dt><i>rate</i></dt> |
---|
55 | <dd>The sampling rate of the source audio.</dd> |
---|
56 | <dt><i>base_quality</i></dt> |
---|
57 | <dd>Desired quality level, currently from -0.1 to 1.0 (lo to hi).</dd> |
---|
58 | </dl> |
---|
59 | |
---|
60 | |
---|
61 | <h3>Return Values</h3> |
---|
62 | <blockquote> |
---|
63 | <li> |
---|
64 | 0 for success</li> |
---|
65 | |
---|
66 | <li>less than zero for failure:</li> |
---|
67 | <ul> |
---|
68 | <li>OV_EFAULT - Internal logic fault; indicates a bug or heap/stack corruption.</li> |
---|
69 | <li>OV_EINVAL - Invalid setup request, eg, out of range argument. </li> |
---|
70 | <li>OV_EIMPL - Unimplemented mode; unable to comply with quality level request.</li> |
---|
71 | </ul> |
---|
72 | </blockquote> |
---|
73 | <p> |
---|
74 | |
---|
75 | <br><br> |
---|
76 | <hr noshade> |
---|
77 | <table border=0 width=100%> |
---|
78 | <tr valign=top> |
---|
79 | <td><p class=tiny>copyright © 2004 xiph.org</p></td> |
---|
80 | <td align=right><p class=tiny><a href="http://www.xiph.org/ogg/vorbis/index.html">Ogg Vorbis</a><br><a href="mailto:team@vorbis.org">team@vorbis.org</a></p></td> |
---|
81 | </tr><tr> |
---|
82 | <td><p class=tiny>libvorbisenc documentation</p></td> |
---|
83 | <td align=right><p class=tiny>libvorbisenc release 1.1 - 20040709</p></td> |
---|
84 | </tr> |
---|
85 | </table> |
---|
86 | |
---|
87 | |
---|
88 | </body> |
---|
89 | |
---|
90 | </html> |
---|