111 lines
7.8 KiB
HTML
111 lines
7.8 KiB
HTML
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
||
|
<html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1">
|
||
|
<title>libmusepack: include/musepack/musepack.h Source File</title>
|
||
|
<link href="custom.css" rel="stylesheet" type="text/css">
|
||
|
</head><body>
|
||
|
<!-- Generated by Doxygen 1.4.1 -->
|
||
|
<div class="qindex"><a class="qindex" href="index.html">Main Page</a> | <a class="qindex" href="annotated.html">Class List</a> | <a class="qindex" href="dirs.html">Directories</a> | <a class="qindex" href="files.html">File List</a> | <a class="qindex" href="globals.html">File Members</a> | <a class="qindex" href="pages.html">Related Pages</a></div>
|
||
|
<div class="nav">
|
||
|
<a class="el" href="dir_000000.html">include</a> / <a class="el" href="dir_000001.html">musepack</a></div>
|
||
|
<h1>musepack.h</h1><a href="musepack_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment">00001 <span class="comment">/*</span>
|
||
|
00002 <span class="comment"> Copyright (c) 2005, The Musepack Development Team</span>
|
||
|
00003 <span class="comment"> All rights reserved.</span>
|
||
|
00004 <span class="comment"></span>
|
||
|
00005 <span class="comment"> Redistribution and use in source and binary forms, with or without</span>
|
||
|
00006 <span class="comment"> modification, are permitted provided that the following conditions are</span>
|
||
|
00007 <span class="comment"> met:</span>
|
||
|
00008 <span class="comment"></span>
|
||
|
00009 <span class="comment"> * Redistributions of source code must retain the above copyright</span>
|
||
|
00010 <span class="comment"> notice, this list of conditions and the following disclaimer.</span>
|
||
|
00011 <span class="comment"></span>
|
||
|
00012 <span class="comment"> * Redistributions in binary form must reproduce the above</span>
|
||
|
00013 <span class="comment"> copyright notice, this list of conditions and the following</span>
|
||
|
00014 <span class="comment"> disclaimer in the documentation and/or other materials provided</span>
|
||
|
00015 <span class="comment"> with the distribution.</span>
|
||
|
00016 <span class="comment"></span>
|
||
|
00017 <span class="comment"> * Neither the name of the The Musepack Development Team nor the</span>
|
||
|
00018 <span class="comment"> names of its contributors may be used to endorse or promote</span>
|
||
|
00019 <span class="comment"> products derived from this software without specific prior</span>
|
||
|
00020 <span class="comment"> written permission.</span>
|
||
|
00021 <span class="comment"></span>
|
||
|
00022 <span class="comment"> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS</span>
|
||
|
00023 <span class="comment"> "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT</span>
|
||
|
00024 <span class="comment"> LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR</span>
|
||
|
00025 <span class="comment"> A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT</span>
|
||
|
00026 <span class="comment"> OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,</span>
|
||
|
00027 <span class="comment"> SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT</span>
|
||
|
00028 <span class="comment"> LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,</span>
|
||
|
00029 <span class="comment"> DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY</span>
|
||
|
00030 <span class="comment"> THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT</span>
|
||
|
00031 <span class="comment"> (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE</span>
|
||
|
00032 <span class="comment"> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.</span>
|
||
|
00033 <span class="comment">*/</span>
|
||
|
00034
|
||
|
00037
|
||
|
00038 <span class="preprocessor">#ifndef _musepack_h_</span>
|
||
|
00039 <span class="preprocessor"></span><span class="preprocessor">#define _musepack_h_</span>
|
||
|
00040 <span class="preprocessor"></span>
|
||
|
00041 <span class="preprocessor">#ifdef __cplusplus</span>
|
||
|
00042 <span class="preprocessor"></span><span class="keyword">extern</span> <span class="stringliteral">"C"</span> {
|
||
|
00043 <span class="preprocessor">#endif</span>
|
||
|
00044 <span class="preprocessor"></span>
|
||
|
00045 <span class="preprocessor">#include <stdio.h></span>
|
||
|
00046 <span class="preprocessor">#include <stdlib.h></span>
|
||
|
00047 <span class="preprocessor">#include <string.h></span>
|
||
|
00048 <span class="preprocessor">#include <math.h></span>
|
||
|
00049
|
||
|
00050 <span class="preprocessor">#include "musepack/config_types.h"</span>
|
||
|
00051 <span class="preprocessor">#include "musepack/decoder.h"</span>
|
||
|
00052 <span class="preprocessor">#include "musepack/math.h"</span>
|
||
|
00053 <span class="preprocessor">#include "<a class="code" href="reader_8h.html">musepack/reader.h</a>"</span>
|
||
|
00054 <span class="preprocessor">#include "<a class="code" href="streaminfo_8h.html">musepack/streaminfo.h</a>"</span>
|
||
|
00055
|
||
|
00056 <span class="keyword">enum</span> {
|
||
|
00057 MPC_FRAME_LENGTH = (36 * 32),
|
||
|
00058 <a class="code" href="musepack_8h.html#a19a8">MPC_DECODER_BUFFER_LENGTH</a> = 4 * MPC_FRAME_LENGTH
|
||
|
00059 };
|
||
|
00060
|
||
|
00061 <span class="comment">// error codes</span>
|
||
|
00062 <span class="preprocessor">#define ERROR_CODE_OK 0</span>
|
||
|
00063 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_FILE -1</span>
|
||
|
00064 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_SV7BETA 1</span>
|
||
|
00065 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_CBR 2</span>
|
||
|
00066 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_IS 3</span>
|
||
|
00067 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_BLOCKSIZE 4</span>
|
||
|
00068 <span class="preprocessor"></span><span class="preprocessor">#define ERROR_CODE_INVALIDSV 5</span>
|
||
|
00069 <span class="preprocessor"></span>
|
||
|
00072 <span class="keywordtype">void</span> <a class="code" href="musepack_8h.html#a9">mpc_streaminfo_init</a>(mpc_streaminfo *si);
|
||
|
00073
|
||
|
00078 mpc_int32_t <a class="code" href="musepack_8h.html#a10">mpc_streaminfo_read</a>(mpc_streaminfo *si, mpc_reader *r);
|
||
|
00079
|
||
|
00082 <span class="keywordtype">double</span> <a class="code" href="musepack_8h.html#a11">mpc_streaminfo_get_length</a>(mpc_streaminfo *si);
|
||
|
00083
|
||
|
00086 mpc_int64_t <a class="code" href="musepack_8h.html#a12">mpc_streaminfo_get_length_samples</a>(mpc_streaminfo *si);
|
||
|
00087
|
||
|
00091 <span class="keywordtype">void</span> <a class="code" href="musepack_8h.html#a13">mpc_decoder_setup</a>(mpc_decoder *d, mpc_reader *r);
|
||
|
00092
|
||
|
00097 BOOL <a class="code" href="musepack_8h.html#a14">mpc_decoder_initialize</a>(mpc_decoder *d, mpc_streaminfo *si);
|
||
|
00098
|
||
|
00102 <span class="keywordtype">void</span> <a class="code" href="musepack_8h.html#a15">mpc_decoder_scale_output</a>(mpc_decoder *d, <span class="keywordtype">double</span> scale_factor);
|
||
|
00103
|
||
|
00112 mpc_uint32_t <a class="code" href="musepack_8h.html#a16">mpc_decoder_decode</a>(
|
||
|
00113 mpc_decoder *d,
|
||
|
00114 MPC_SAMPLE_FORMAT *buffer,
|
||
|
00115 mpc_uint32_t *vbr_update_acc,
|
||
|
00116 mpc_uint32_t *vbr_update_bits);
|
||
|
00117
|
||
|
00119 BOOL <a class="code" href="musepack_8h.html#a17">mpc_decoder_seek_sample</a>(mpc_decoder *d, mpc_int64_t destsample);
|
||
|
00120
|
||
|
00122 BOOL <a class="code" href="musepack_8h.html#a18">mpc_decoder_seek_seconds</a>(mpc_decoder *d, <span class="keywordtype">double</span> seconds);
|
||
|
00123
|
||
|
00124 <span class="preprocessor">#ifdef __cplusplus</span>
|
||
|
00125 <span class="preprocessor"></span>}
|
||
|
00126 <span class="preprocessor">#endif // __cplusplus</span>
|
||
|
00127 <span class="preprocessor"></span>
|
||
|
00128 <span class="preprocessor">#endif // _musepack_h_</span>
|
||
|
</pre></div><hr size="1"><address style="align: right;"><small>Generated on Sat Jan 22 09:34:06 2005 for libmusepack by
|
||
|
<a href="http://www.doxygen.org/index.html">
|
||
|
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.4.1 </small></address>
|
||
|
</body>
|
||
|
</html>
|