Installer update
[xiph/unicode.git] / ao / doc / ao_device.html
blobd8ccf3e5157873796ba0cc072479a7c3e47f4447
1 <html>
3 <head>
4 <title>libao - datatype - ao_device</title>
5 <link rel=stylesheet href="style.css" type="text/css">
6 </head>
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>libao documentation</p></td>
12 <td align=right><p class=tiny>libao version 0.8.5 - 20040312</p></td>
13 </tr>
14 </table>
16 <h1>ao_device</h1>
18 <p><i>declared in "ao/ao.h";</i></p>
20 <p>This structure holds all of the data for an open device.
22 <br><br>
23 <table border=0 width=100% color=black cellspacing=0 cellpadding=7>
24 <tr bgcolor=#cccccc>
25 <td>
26 <pre><b>typedef struct {
27 int type; /* live output or file output? */
28 int driver_id;
29 ao_functions *funcs;
30 FILE *file; /* File for output if this is a file driver */
31 int client_byte_format;
32 int machine_byte_format;
33 int driver_byte_format;
34 char *swap_buffer;
35 int swap_buffer_size; /* Bytes allocated to swap_buffer */
36 void *internal; /* Pointer to driver-specific data */
37 } ao_device;</b></pre>
38 </td>
39 </tr>
40 </table>
42 <h3>Relevant Struct Members</h3>
43 <dl>
44 <dt><i>type</i></dt>
45 <dd>The output type of the driver:
46 <ul>
47 <li>AO_TYPE_LIVE - Live output.</li>
48 <li>AO_TYPE_FILE - File output.</li>
49 </ul>
50 </dd>
51 <dt><i>driver_id</i></dt>
52 <dd>The ID number for the driver used with this device.</dd>
53 <dt><i>funcs</i></dt>
54 <dd>Function table for the driver associated with this device.</dd>
55 <dt><i>client_byte_format</i></dt>
56 <dd>The byte format (use constants from
57 <a href="ao_sample_format.html">ao_sample_format</a>) of samples provided by
58 the client to <a href="ao_sample_format.html">ao_play()</a>.
59 </dd>
60 <dt><i>machine_byte_format</i></dt>
61 <dd>The native byte format of the computer. Will be either
62 <tt>AO_FMT_BIG</tt> or <tt>AO_FMT_LITTLE</tt>.
63 </dd>
64 <dt><i>driver_byte_format</i></dt>
65 <dd>The byte format of samples requested by
66 the driver.
67 </dd>
68 <dt><i>swap_buffer</i></dt>
69 <dd>Scratch buffer used to swap the byte order of samples. Only allocated
70 if <tt>client_byte_format</tt> and <tt>driver_byte_format</tt> correspond to
71 different byte orders, otherwise set to NULL</dd>
72 </dl>
74 <br><br>
75 <hr noshade>
76 <table border=0 width=100%>
77 <tr valign=top>
78 <td><p class=tiny>copyright &copy; 2001-2003 Stan Seibert</p></td>
79 <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>
80 </tr><tr>
81 <td><p class=tiny>libao documentation</p></td>
82 <td align=right><p class=tiny>libao version 0.8.5 - 20040312</p></td>
83 </tr>
84 </table>
86 </body>
88 </html>