4 <title>libao - function - ao_open_live
</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
>libao documentation
</p></td>
12 <td align=right
><p class=tiny
>libao version
0.8.5 -
20040312</p></td>
18 <p><i>declared in
"ao/ao.h";
</i></p>
20 <p>Open a live playback audio device for output.
23 <table border=
0 color=black cellspacing=
0 cellpadding=
7>
27 <a href=
"ao_device.html">ao_device
</a>* ao_open_live(int driver_id,
<a href=
"ao_sample_format.html">ao_sample_format
</a> *format,
<a href=
"ao_option.html">ao_option
</a> *options);
35 <dt><i>driver_id
</i></dt>
36 <dd>The ID number of the driver as returned by either
37 <a href=
"ao_driver_id.html">ao_driver_id()
</a> or
38 <a href=
"ao_default_driver_id.html">ao_default_driver_id()
</a>.
</dd>
39 <dt><i>format
</i></dt>
40 <dd>Pointer to a struct describing the sample format. The caller retains ownership of this structure.
</dd>
41 <dt><i>options
</i></dt>
42 <dd>A linked list of options to be passed to the driver or NULL if no options
43 are needed. Unsupported options are ignored.
</dd>
46 <h3>Return Values
</h3>
49 non-NULL pointer inicates success. This pointer must be passed in subsequent
50 calls to
<a href=
"ao_play.html">ao_play()
</a> and
51 <a href=
"ao_close.html">ao_close()
</a>.
</li>
53 <li>NULL indicates failure.
<tt>errno
</tt> will contain the specific cause of the failure:
</li>
55 <li>AO_ENODRIVER - No driver corresponds to
<tt>driver_id
</tt>.
</li>
56 <li>AO_ENOTLIVE - This driver is not a live output device.
</li>
57 <li>AO_EBADOPTION - A valid option key has an invalid value.
</li>
58 <li>AO_EOPENDEVICE - Cannot open the device (for example, if /dev/dsp cannot be
59 opened for writing).
</li>
60 <li>AO_EFAIL - Any other cause of failure.
</li>
68 <p>File output drivers cannot be used with this function. Use
<a
69 href=
"ao_open_file.html">ao_open_file()
</a> instead.
73 <table border=
0 width=
100%
>
75 <td><p class=tiny
>copyright
© 2001-
2003 Stan Seibert
</p></td>
76 <td align=right
><p class=tiny
><a href=
"http://www.xiph.org/">xiph.org
</a><br><a href=
"mailto:volsung@xiph.org">volsung@xiph.org
</a></p></td>
78 <td><p class=tiny
>libao documentation
</p></td>
79 <td align=right
><p class=tiny
>libao version
0.8.5 -
20040312</p></td>