Numerous corrections and updates to libVorbisfile docs
[platform/upstream/libvorbis.git] / doc / vorbisfile / ov_read_float.html
1 <html>
2
3 <head>
4 <title>Vorbisfile - function - ov_read_float</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>vorbisfile documentation</p></td>
12 <td align=right><p class=tiny>libVorbisfile version 1.65 - 20020702</p></td>
13 </tr>
14 </table>
15
16 <h1>ov_read_float()</h1>
17
18 <p><i>declared in "vorbis/vorbisfile.h";</i></p>
19
20 <p>
21    This is the function used to decode a Vorbis file within a loop, but
22    returns samples in native float format instead of in integer formats.
23 </p><p>
24    For more information on how ov_read_float() deals with the complex issues 
25    of chaining, etc, refer to the documentation for <a href="ov_read.html">ov_read()</a>.
26 </p>
27
28 <br><br>
29 <table border=0 color=black cellspacing=0 cellpadding=7>
30 <tr bgcolor=#cccccc>
31         <td>
32 <pre><b>
33 long ov_read(<a href="OggVorbis_File.html">OggVorbis_File</a> *vf, float ***pcm_channels, int *bitstream);
34 </b></pre>
35         </td>
36 </tr>
37 </table>
38
39 <h3>Parameters</h3>
40 <dl>
41 <dt><i>vf</i></dt>
42 <dd>A pointer to the OggVorbis_File structure--this is used for ALL the externally visible vorbisfile
43 functions.</dd>
44 <dt><i>pcm_channels</i></dt>
45 <dd>A pointer to an output buffer.  The pointer will be set to the decoded output buffer.</dd>
46 <dt><i>bitstream</i></dt>
47 <dd>A pointer to the number of the current logical bitstream.</dd>
48 </dl>
49
50
51 <h3>Return Values</h3>
52 <blockquote>
53 <dl>
54 <dt>OV_HOLE</dt>
55   <dd>indicates there was an interruption in the data.
56       <br>(one of: garbage between pages, loss of sync followed by
57            recapture, or a corrupt page)</dd>
58 <dt>OV_EBADLINK</dt>
59   <dd>indicates that an invalid stream section was supplied to
60       libvorbisfile, or the requested link is corrupt.</dd>
61 <dt>0</dt>
62   <dd>indicates EOF</dd>
63 <dt><i>n</i></dt>
64   <dd>indicates actual number of bytes read.  <tt>ov_read()</tt> will
65       decode at most one vorbis packet per invocation, so the value
66       returned will generally be less than <tt>length</tt>.
67 </dl>
68 </blockquote>
69
70 <h3>Notes</h3>
71 <p><b>Typical usage:</b>
72 <blockquote>
73 <tt>float **pcm;
74 bytes_read = ov_read_float(&amp;vf,pcm,&amp;current_section)</tt>
75 </blockquote>
76
77 This decodes one packet's worth of float samples.
78 </p>
79
80 <br>
81 <br><br>
82 <hr noshade>
83 <table border=0 width=100%>
84 <tr valign=top>
85 <td><p class=tiny>copyright &copy; 2002 vorbis team</p></td>
86 <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>
87 </tr><tr>
88 <td><p class=tiny>vorbisfile documentation</p></td>
89 <td align=right><p class=tiny>libVorbisfile version 1.65 - 20020702</p></td>
90 </tr>
91 </table>
92
93
94 </body>
95
96 </html>
97
98
99