annotate src/libvorbis-1.3.3/doc/libvorbis/vorbis_analysis.html @ 1:05aa0afa9217

Bring in flac, ogg, vorbis
author Chris Cannam
date Tue, 19 Mar 2013 17:37:49 +0000
parents
children
rev   line source
Chris@1 1 <html>
Chris@1 2
Chris@1 3 <head>
Chris@1 4 <title>libvorbis - function - vorbis_analysis</title>
Chris@1 5 <link rel=stylesheet href="style.css" type="text/css">
Chris@1 6 </head>
Chris@1 7
Chris@1 8 <body bgcolor=white text=black link="#5555ff" alink="#5555ff" vlink="#5555ff">
Chris@1 9 <table border=0 width=100%>
Chris@1 10 <tr>
Chris@1 11 <td><p class=tiny>libvorbis documentation</p></td>
Chris@1 12 <td align=right><p class=tiny>libvorbis version 1.3.2 - 20101101</p></td>
Chris@1 13 </tr>
Chris@1 14 </table>
Chris@1 15
Chris@1 16 <h1>vorbis_analysis</h1>
Chris@1 17
Chris@1 18 <p><i>declared in "vorbis/codec.h";</i></p>
Chris@1 19
Chris@1 20 <p>Once the uncompressed audio data has been divided into blocks, this
Chris@1 21 function is called on each block. It looks up the encoding mode and
Chris@1 22 dispatches the block to the forward transform provided by that mode.
Chris@1 23 </p>
Chris@1 24 <p>When using a basic encoding mode, with no bitrate management,
Chris@1 25 an ogg_packet pointer can be given, and the coded block is returned
Chris@1 26 directly through that structure and can be placed in the output stream.
Chris@1 27 </p>
Chris@1 28 <p>Otherwise, NULL should be passed for the ogg_packet pointer. In
Chris@1 29 that case, after the transform has been applied, the block must passed
Chris@1 30 to vorbis_bitrate_addblock() for further coding. This method works with
Chris@1 31 both basic and managed encoding modes, so it's recommended for new code.
Chris@1 32 </p>
Chris@1 33
Chris@1 34 <table border=0 color=black cellspacing=0 cellpadding=7>
Chris@1 35 <tr bgcolor=#cccccc>
Chris@1 36 <td>
Chris@1 37 <pre><b>
Chris@1 38 extern int vorbis_analysis(vorbis_block *vb,ogg_packet *op);
Chris@1 39 </b></pre>
Chris@1 40 </td>
Chris@1 41 </tr>
Chris@1 42 </table>
Chris@1 43
Chris@1 44 <h3>Parameters</h3>
Chris@1 45 <dl>
Chris@1 46 <dt><i>vb</i></dt>
Chris@1 47 <dd>Pointer to the vorbis_block to be encoded.</dd>
Chris@1 48 <dt><i>op</i></dt>
Chris@1 49 <dd>Optional pointer to an ogg_packet. This is normally NULL,
Chris@1 50 and the final output is obtained by passing <i>vb</i> though the
Chris@1 51 vorbis_bitrate_*() interface to perform further refinement.
Chris@1 52 However, when not using a bitrate managed encoding mode, it
Chris@1 53 is possible to skip that step by providing an ogg_packet pointer
Chris@1 54 here, obtaining the compressed data directly.</dd>
Chris@1 55 </dl>
Chris@1 56
Chris@1 57
Chris@1 58 <h3>Return Values</h3>
Chris@1 59 <ul>
Chris@1 60 <li>0 for success</li>
Chris@1 61 <li>negative values for failure:
Chris@1 62 <ul>
Chris@1 63 <li>OV_EINVAL - Invalid request; a non-NULL value was passed for <i>op</i> when the encoder is using a bitrate managed mode.</li>
Chris@1 64 <li>OV_EFAULT - Internal fault; indicates a bug or memory corruption.</li>
Chris@1 65 <li>OV_EIMPL - Unimplemented; not supported by this version of the library.</li>
Chris@1 66 </ul>
Chris@1 67 </li>
Chris@1 68 </ul>
Chris@1 69 <p>
Chris@1 70
Chris@1 71 <br><br>
Chris@1 72 <hr noshade>
Chris@1 73 <table border=0 width=100%>
Chris@1 74 <tr valign=top>
Chris@1 75 <td><p class=tiny>copyright &copy; 2010 Xiph.Org</p></td>
Chris@1 76 <td align=right><p class=tiny><a href="http://www.xiph.org/ogg/vorbis/index.html">Ogg Vorbis</a></p></td>
Chris@1 77 </tr><tr>
Chris@1 78 <td><p class=tiny>libvorbis documentation</p></td>
Chris@1 79 <td align=right><p class=tiny>libvorbis version 1.3.2 - 20101101</p></td>
Chris@1 80 </tr>
Chris@1 81 </table>
Chris@1 82
Chris@1 83
Chris@1 84 </body>
Chris@1 85
Chris@1 86 </html>