4 <title>libvorbisenc - function - vorbis_encode_setup_init</title>
5 <link rel=stylesheet href="style.css" type="text/css">
8 <body bgcolor=white text=black link="#5555ff" alink="#5555ff" vlink="#5555ff">
9 <table border=0 width=100%>
11 <td><p class=tiny>libvorbisenc documentation</p></td>
12 <td align=right><p class=tiny>libvorbisenc release 1.1 - 20040709</p></td>
16 <h1>vorbis_encode_setup_init</h1>
18 <p><i>declared in "vorbis/libvorbisenc.h";</i></p>
20 <p>This function performs the last stage of three-step encoding setup, as described in the API overview under <a href="overview.html#BBR">managed bitrate modes</a>.
22 <p>Before this function is called, the <a
23 href="vorbis_info.html">vorbis_info</a> struct should be initialized
24 by using vorbis_info_init() from the libvorbis API, one of <a
25 href="vorbis_encode_setup_managed.html">vorbis_encode_setup_managed()</a>
27 href="vorbis_encode_setup_vbr.html">vorbis_encode_setup_vbr()</a>
28 called to initialize the high-level encoding setup, and <a
29 href="vorbis_encode_ctl.html">vorbis_encode_ctl()</a> called if
30 necessary to make encoding setup changes. vorbis_encode_setup_init()
31 finalizes the highlevel encoding structure into a complete encoding
32 setup after which the application may make no further setup changes.<p>
34 After encoding, vorbis_info_clear should be called.
37 <table border=0 color=black cellspacing=0 cellpadding=7>
41 extern int vorbis_encode_setup_init(<a href="vorbis_info.html">vorbis_info</a> *vi);
51 <dd>File pointer to an initialized <a href="vorbis_info.html">vorbis_info</a> struct.</dd>
55 <h3>Return Values</h3>
60 <li>less than zero for failure:</li>
62 <li>OV_EFAULT - Internal logic fault; indicates a bug or heap/stack corruption.</li>
63 <li>OV_EINVAL - Attempt to use vorbis_encode_setup_init() without first calling one of <a
64 href="vorbis_encode_setup_managed.html">vorbis_encode_setup_managed()</a>
66 href="vorbis_encode_setup_vbr.html">vorbis_encode_setup_vbr()</a>
67 to initialize the high-level encoding setup
75 <table border=0 width=100%>
77 <td><p class=tiny>copyright © 2004 xiph.org</p></td>
78 <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>
80 <td><p class=tiny>libvorbisenc documentation</p></td>
81 <td align=right><p class=tiny>libvorbisenc release 1.1 - 20040709</p></td>