API documentation for libmpg123, libout123, and libsyn123

Note: This API doc is automatically generated from the current development version that you can get via Subversion or as a daily snapshot from http://mpg123.org/snapshot. There may be differences (additions) compared to the latest stable release. See NEWS.libmpg123, NEWS.libout123, NEWS.libsyn123, and the overall NEWS file on libmpg123 versions and important changes between them.
Let me emphasize that the policy for the lib*123 family is to always stay backwards compatible -- only additions are planned (and it's not yet planned to change the plans;-).
mpg123.h
Go to the documentation of this file.
1 /*
2  libmpg123: MPEG Audio Decoder library
3 
4  copyright 1995-2023 by the mpg123 project
5  free software under the terms of the LGPL 2.1
6  see COPYING and AUTHORS files in distribution or http://mpg123.org
7 */
8 
9 #ifndef MPG123_LIB_H
10 #define MPG123_LIB_H
11 
12 #include "fmt123.h"
13 
24 #define MPG123_API_VERSION 49
26 #define MPG123_PATCHLEVEL 3
27 
28 #ifndef MPG123_EXPORT
36 #ifdef BUILD_MPG123_DLL
37 /* The dll exports. */
38 #define MPG123_EXPORT __declspec(dllexport)
39 #else
40 #ifdef LINK_MPG123_DLL
41 /* The exe imports. */
42 #define MPG123_EXPORT __declspec(dllimport)
43 #else
44 /* Nothing on normal/UNIX builds */
45 #define MPG123_EXPORT
46 #endif
47 #endif
48 #endif
49 
78 #ifndef MPG123_ENUM_API
79 
80 #define mpg123_param mpg123_param2
81 #define mpg123_getparam mpg123_getparam2
82 #define mpg123_feature mpg123_feature2
83 #define mpg123_eq mpg123_eq2
84 #define mpg123_geteq mpg123_geteq2
85 #define mpg123_frameinfo mpg123_frameinfo2
86 #define mpg123_info mpg123_info2
87 #define mpg123_getstate mpg123_getstate2
88 #define mpg123_enc_from_id3 mpg123_enc_from_id3_2
89 #define mpg123_store_utf8 mpg123_store_utf8_2
90 #define mpg123_par mpg123_par2
91 #define mpg123_getpar mpg123_getpar2
92 
93 #endif
94 
95 #include <stddef.h>
96 #include <stdint.h>
97 
98 #ifndef MPG123_PORTABLE_API
99 #include <sys/types.h>
101 #ifdef _MSC_VER
102 typedef ptrdiff_t mpg123_ssize_t;
103 #else
104 typedef ssize_t mpg123_ssize_t;
105 #endif
106 #endif
107 
108 
135 #ifndef MPG123_PORTABLE_API
165 #if (!defined MPG123_NO_LARGENAME) && ((defined _FILE_OFFSET_BITS) || (defined MPG123_LARGESUFFIX))
166 
167 /* Need some trickery to concatenate the value(s) of the given macro(s). */
168 #define MPG123_MACROCAT_REALLY(a, b) a ## b
169 #define MPG123_MACROCAT(a, b) MPG123_MACROCAT_REALLY(a, b)
170 #ifndef MPG123_LARGESUFFIX
171 #define MPG123_LARGESUFFIX MPG123_MACROCAT(_, _FILE_OFFSET_BITS)
172 #endif
173 #define MPG123_LARGENAME(func) MPG123_MACROCAT(func, MPG123_LARGESUFFIX)
174 
175 #define mpg123_open_fixed MPG123_LARGENAME(mpg123_open_fixed)
176 #define mpg123_open MPG123_LARGENAME(mpg123_open)
177 #define mpg123_open_fd MPG123_LARGENAME(mpg123_open_fd)
178 #define mpg123_open_handle MPG123_LARGENAME(mpg123_open_handle)
179 #define mpg123_framebyframe_decode MPG123_LARGENAME(mpg123_framebyframe_decode)
180 #define mpg123_decode_frame MPG123_LARGENAME(mpg123_decode_frame)
181 #define mpg123_tell MPG123_LARGENAME(mpg123_tell)
182 #define mpg123_tellframe MPG123_LARGENAME(mpg123_tellframe)
183 #define mpg123_tell_stream MPG123_LARGENAME(mpg123_tell_stream)
184 #define mpg123_seek MPG123_LARGENAME(mpg123_seek)
185 #define mpg123_feedseek MPG123_LARGENAME(mpg123_feedseek)
186 #define mpg123_seek_frame MPG123_LARGENAME(mpg123_seek_frame)
187 #define mpg123_timeframe MPG123_LARGENAME(mpg123_timeframe)
188 #define mpg123_index MPG123_LARGENAME(mpg123_index)
189 #define mpg123_set_index MPG123_LARGENAME(mpg123_set_index)
190 #define mpg123_position MPG123_LARGENAME(mpg123_position)
191 #define mpg123_length MPG123_LARGENAME(mpg123_length)
192 #define mpg123_framelength MPG123_LARGENAME(mpg123_framelength)
193 #define mpg123_set_filesize MPG123_LARGENAME(mpg123_set_filesize)
194 #define mpg123_replace_reader MPG123_LARGENAME(mpg123_replace_reader)
195 #define mpg123_replace_reader_handle MPG123_LARGENAME(mpg123_replace_reader_handle)
196 #define mpg123_framepos MPG123_LARGENAME(mpg123_framepos)
197 
198 #endif /* largefile hackery */
199 #endif
200 
203 #ifdef __cplusplus
204 extern "C" {
205 #endif
206 
217 struct mpg123_handle_struct;
218 
222 typedef struct mpg123_handle_struct mpg123_handle;
223 
231 const char *mpg123_distversion(unsigned int *major, unsigned int *minor, unsigned int *patch);
232 
237 unsigned int mpg123_libversion(unsigned int *patch);
238 
253 
260 
269 MPG123_EXPORT mpg123_handle *mpg123_new(const char* decoder, int *error);
270 
275 
281 MPG123_EXPORT void mpg123_free(void *ptr);
282 
285 {
311 };
312 
315 {
316  MPG123_FORCE_MONO = 0x7
322  ,MPG123_QUIET = 0x20
323  ,MPG123_GAPLESS = 0x40
326  ,MPG123_FUZZY = 0x200
330  ,MPG123_SKIP_ID3V2 = 0x2000
333  ,MPG123_PICTURE = 0x10000
334  ,MPG123_NO_PEEK_END = 0x20000
342  ,MPG123_FORCE_ENDIAN = 0x100000
348  ,MPG123_BIG_ENDIAN = 0x200000
349  ,MPG123_NO_READAHEAD = 0x400000
372 };
373 
376 {
377  MPG123_RVA_OFF = 0
381 };
382 
383 #ifdef MPG123_ENUM_API
396 , enum mpg123_parms type, long value, double fvalue );
397 #endif
398 
411 , int type, long value, double fvalue );
412 
413 #ifdef MPG123_ENUM_API
426 , enum mpg123_parms type, long *value, double *fvalue );
427 #endif
428 
441 , int type, long *value, double *fvalue );
442 
445 {
464 };
465 
466 #ifdef MPG123_ENUM_API
476 #endif
477 
487 
524 {
574 };
575 
580 MPG123_EXPORT const char* mpg123_plain_strerror(int errcode);
581 
590 
596 
611 MPG123_EXPORT const char **mpg123_decoders(void);
612 
621 
627 MPG123_EXPORT int mpg123_decoder(mpg123_handle *mh, const char* decoder_name);
628 
639 
667 {
668  MPG123_MONO = 1
670 };
671 
679 MPG123_EXPORT void mpg123_rates(const long **list, size_t *number);
680 
685 MPG123_EXPORT void mpg123_encodings(const int **list, size_t *number);
686 
690 MPG123_EXPORT int mpg123_encsize(int encoding);
691 
698 
705 
713 , long rate, int channels, int encodings );
714 
726 , long rate, int channels, int encodings );
727 
736 , long rate, int encoding );
737 
750 , long *rate, int *channels, int *encoding );
751 
764 , long *rate, int *channels, int *encoding, int clear_flag );
765 
776 #ifndef MPG123_PORTABLE_API
821 , int channels, int encoding);
822 
838 MPG123_EXPORT int mpg123_open(mpg123_handle *mh, const char *path);
839 
847 #endif
848 
857 MPG123_EXPORT int mpg123_open64(mpg123_handle *mh, void *iohandle);
858 
868 
877 
883 
896 , void *outmemory, size_t outmemsize, size_t *done );
897 
906 , const unsigned char *in, size_t size );
907 
928 , const unsigned char *inmemory, size_t inmemsize
929 , void *outmemory, size_t outmemsize, size_t *done );
930 
931 #ifndef MPG123_PORTABLE_API
941 , off_t *num, unsigned char **audio, size_t *bytes );
942 
953 , off_t *num, unsigned char **audio, size_t *bytes );
954 #endif /* un-portable API */
955 
965 , int64_t *num, unsigned char **audio, size_t *bytes );
966 
977 , int64_t *num, unsigned char **audio, size_t *bytes );
978 
986 
1003 , unsigned long *header, unsigned char **bodydata, size_t *bodybytes );
1004 
1005 #ifndef MPG123_PORTABLE_API
1014 #endif
1015 
1024 
1076 #ifndef MPG123_PORTABLE_API
1083 #endif
1084 
1091 
1092 #ifndef MPG123_PORTABLE_API
1098 #endif
1099 
1105 
1106 #ifndef MPG123_PORTABLE_API
1112 #endif
1113 
1119 
1120 
1121 #ifndef MPG123_PORTABLE_API
1132 , off_t sampleoff, int whence );
1133 #endif
1134 
1144 , int64_t sampleoff, int whence );
1145 
1146 #ifndef MPG123_PORTABLE_API
1160 , off_t sampleoff, int whence, off_t *input_offset );
1161 #endif
1162 
1175 , int64_t sampleoff, int whence, int64_t *input_offset );
1176 
1177 #ifndef MPG123_PORTABLE_API
1187 , off_t frameoff, int whence );
1188 #endif
1189 
1198 , int64_t frameoff, int whence );
1199 
1200 #ifndef MPG123_PORTABLE_API
1205 
1218 , off_t **offsets, off_t *step, size_t *fill );
1219 #endif
1220 
1225 
1236 , int64_t **offsets, int64_t *step, size_t *fill );
1237 
1238 #ifndef MPG123_PORTABLE_API
1251 , off_t *offsets, off_t step, size_t fill );
1252 #endif
1253 
1264 , int64_t *offsets, int64_t step, size_t fill );
1265 
1266 
1267 #ifndef MPG123_PORTABLE_API
1275 MPG123_EXPORT int mpg123_position( mpg123_handle *mh, off_t INT123_frame_offset, off_t buffered_bytes, off_t *current_frame, off_t *frames_left, double *current_seconds, double *seconds_left);
1276 #endif
1277 
1288 {
1289  MPG123_LEFT=0x1
1292 };
1293 
1294 #ifdef MPG123_ENUM_API
1308 , enum mpg123_channels channel, int band, double val );
1309 #endif
1310 
1324 , int channel, int band, double val );
1325 
1336 , int channel, int a, int b, double factor );
1337 
1348 , int channel, int a, int b, double db );
1349 
1350 #ifdef MPG123_ENUM_API
1362  , enum mpg123_channels channel, int band);
1363 #endif
1364 
1375 MPG123_EXPORT double mpg123_geteq2(mpg123_handle *mh, int channel, int band);
1376 
1382 
1390 
1397 
1404 
1415 MPG123_EXPORT int mpg123_getvolume(mpg123_handle *mh, double *base, double *really, double *rva_db);
1416 
1417 /* TODO: Set some preamp in addition / to replace internal RVA handling? */
1418 
1431  MPG123_ABR
1432 };
1433 
1438  MPG123_2_5
1439 };
1440 
1441 
1448  MPG123_M_MONO
1449 };
1450 
1451 
1457  MPG123_ORIGINAL=0x8
1458 };
1459 
1460 #ifdef MPG123_ENUM_API
1463 {
1464  enum mpg123_version version;
1465  int layer;
1466  long rate;
1467  enum mpg123_mode mode;
1468  int mode_ext;
1470  enum mpg123_flags flags;
1471  int emphasis;
1472  int bitrate;
1473  int abr_rate;
1474  enum mpg123_vbr vbr;
1475 };
1476 #endif
1477 
1480 {
1481  int version;
1482  int layer;
1483  long rate;
1484  int mode;
1485  int mode_ext;
1487  int flags;
1488  int emphasis;
1489  int bitrate;
1490  int abr_rate;
1491  int vbr;
1492 };
1493 
1500 {
1501  double xr[2][2][576];
1502  double sfb[2][2][22];
1503  double sfb_s[2][2][3*13];
1504  int qss[2][2];
1505  int big_values[2][2];
1506  int sub_gain[2][2][3];
1507  int scalefac_scale[2][2];
1508  int preflag[2][2];
1509  int blocktype[2][2];
1510  int mixed[2][2];
1511  int mainbits[2][2];
1512  int sfbits[2][2];
1513  int scfsi[2];
1514  int maindata;
1515  int padding;
1516 };
1517 
1518 #ifdef MPG123_ENUM_API
1530 #endif
1531 
1543 
1551 , struct mpg123_moreinfo *mi );
1552 
1558 
1567 
1568 #ifndef MPG123_PORTABLE_API
1575 
1589 
1597 #endif
1598 
1605 
1619 
1627 
1633 
1639 
1645 
1646 
1649 {
1650  MPG123_ACCURATE = 1
1657 };
1658 
1659 #ifdef MPG123_ENUM_API
1672 , enum mpg123_state key, long *val, double *fval );
1673 #endif
1674 
1687 , int key, long *val, double *fval );
1688 
1702 typedef struct
1703 {
1704  char* p;
1705  size_t size;
1706  size_t fill;
1707 } mpg123_string;
1708 
1713 
1718 
1725 
1732 
1739 
1750 
1758 
1772 
1778 MPG123_EXPORT int mpg123_add_string(mpg123_string* sb, const char* stuff);
1779 
1788 , const char *stuff, size_t from, size_t count );
1789 
1795 MPG123_EXPORT int mpg123_set_string(mpg123_string* sb, const char* stuff);
1796 
1805 , const char *stuff, size_t from, size_t count );
1806 
1816 
1822 
1831 
1834 {
1835  mpg123_text_unknown = 0
1850 };
1851 
1854 {
1855  mpg123_id3_latin1 = 0
1860 };
1861 
1862 #ifdef MPG123_ENUM_API
1871 MPG123_EXPORT enum mpg123_text_encoding mpg123_enc_from_id3(unsigned char id3_enc_byte);
1872 #endif
1873 
1882 MPG123_EXPORT int mpg123_enc_from_id3_2(unsigned char id3_enc_byte);
1883 
1884 #ifdef MPG123_ENUM_API
1898 MPG123_EXPORT int mpg123_store_utf8(mpg123_string *sb, enum mpg123_text_encoding enc, const unsigned char *source, size_t source_size);
1899 #endif
1900 
1915 , int enc, const unsigned char *source, size_t source_size);
1916 
1923 typedef struct
1924 {
1925  char lang[3];
1926  char id[4];
1929 } mpg123_text;
1930 
1933 {
1955 };
1956 
1961 typedef struct
1962 {
1963  char type;
1966  size_t size;
1967  unsigned char* data;
1968 } mpg123_picture;
1969 
1975 typedef struct
1976 {
1977  unsigned char version;
1984  /* Encountered ID3v2 fields are appended to these lists.
1985  There can be multiple occurences, the pointers above always point to the last encountered data. */
1987  size_t comments;
1989  size_t texts;
1991  size_t extras;
1994  size_t pictures;
1995 } mpg123_id3v2;
1996 
2001 typedef struct
2002 {
2003  char tag[3];
2004  char title[30];
2005  char artist[30];
2006  char album[30];
2007  char year[4];
2008  char comment[30];
2009  unsigned char genre;
2010 } mpg123_id3v1;
2011 
2012 #define MPG123_ID3 0x3
2013 #define MPG123_NEW_ID3 0x1
2014 #define MPG123_ICY 0xc
2015 #define MPG123_NEW_ICY 0x4
2022 
2027 
2033 , mpg123_id3v1 **v1, mpg123_id3v2 **v2 );
2034 
2049 , unsigned char **v1, size_t *v1_size
2050 , unsigned char **v2, size_t *v2_size );
2051 
2057 MPG123_EXPORT int mpg123_icy(mpg123_handle *mh, char **icy_meta);
2058 
2063 MPG123_EXPORT char* mpg123_icy2utf8(const char* icy_text);
2064 
2065 
2085 struct mpg123_pars_struct;
2086 
2088 typedef struct mpg123_pars_struct mpg123_pars;
2089 
2097 , const char* decoder, int *error );
2098 
2104 
2109 
2116 
2123 
2134 , long rate, int channels, int encodings);
2135 
2147 , long rate, int channels, int encodings);
2148 
2156 MPG123_EXPORT int mpg123_fmt_support(mpg123_pars *mp, long rate, int encoding);
2157 
2158 #ifdef MPG123_ENUM_API
2171 , enum mpg123_parms type, long value, double fvalue );
2172 #endif
2173 
2186 , int type, long value, double fvalue );
2187 
2188 #ifdef MPG123_ENUM_API
2201 , enum mpg123_parms type, long *value, double *fvalue );
2202 #endif
2203 
2216 , int type, long *value, double *fvalue );
2217 
2241 , void *data, size_t size);
2242 
2249 
2250 #ifndef MPG123_PORTABLE_API
2265 , mpg123_ssize_t (*r_read) (int, void *, size_t)
2266 , off_t (*r_lseek)(int, off_t, int)
2267 );
2268 
2284 , mpg123_ssize_t (*r_read) (void *, void *, size_t)
2285 , off_t (*r_lseek)(void *, off_t, int)
2286 , void (*cleanup)(void*) );
2287 #endif
2288 
2308 MPG123_EXPORT int mpg123_reader64( mpg123_handle *mh, int (*r_read) (void *, void *, size_t, size_t *), int64_t (*r_lseek)(void *, int64_t, int), void (*cleanup)(void*) );
2309 
2312 #ifdef __cplusplus
2313 }
2314 #endif
2315 
2316 #endif
MPG123_EXPORT int mpg123_getpar(mpg123_pars *mp, enum mpg123_parms type, long *value, double *fvalue)
struct mpg123_pars_struct mpg123_pars
Definition: mpg123.h:2088
MPG123_EXPORT int mpg123_fmt2(mpg123_pars *mp, long rate, int channels, int encodings)
MPG123_EXPORT int mpg123_getpar2(mpg123_pars *mp, int type, long *value, double *fvalue)
MPG123_EXPORT int mpg123_fmt(mpg123_pars *mp, long rate, int channels, int encodings)
MPG123_EXPORT int mpg123_par2(mpg123_pars *mp, int type, long value, double fvalue)
MPG123_EXPORT int mpg123_fmt_support(mpg123_pars *mp, long rate, int encoding)
MPG123_EXPORT void mpg123_delete_pars(mpg123_pars *mp)
MPG123_EXPORT int mpg123_par(mpg123_pars *mp, enum mpg123_parms type, long value, double fvalue)
MPG123_EXPORT mpg123_handle * mpg123_parnew(mpg123_pars *mp, const char *decoder, int *error)
MPG123_EXPORT mpg123_pars * mpg123_new_pars(int *error)
MPG123_EXPORT int mpg123_fmt_all(mpg123_pars *mp)
MPG123_EXPORT int mpg123_fmt_none(mpg123_pars *mp)
MPG123_EXPORT const char ** mpg123_supported_decoders(void)
MPG123_EXPORT const char * mpg123_current_decoder(mpg123_handle *mh)
MPG123_EXPORT const char ** mpg123_decoders(void)
MPG123_EXPORT int mpg123_decoder(mpg123_handle *mh, const char *decoder_name)
MPG123_EXPORT const char * mpg123_strerror(mpg123_handle *mh)
MPG123_EXPORT int mpg123_errcode(mpg123_handle *mh)
mpg123_errors
Definition: mpg123.h:524
MPG123_EXPORT const char * mpg123_plain_strerror(int errcode)
@ MPG123_NEED_MORE
Definition: mpg123.h:527
@ MPG123_LSEEK_FAILED
Definition: mpg123.h:569
@ MPG123_BAD_PARAM
Definition: mpg123.h:534
@ MPG123_ERR_16TO8TABLE
Definition: mpg123.h:533
@ MPG123_BAD_CHANNEL
Definition: mpg123.h:531
@ MPG123_NO_SEEK
Definition: mpg123.h:552
@ MPG123_BAD_PARS
Definition: mpg123.h:554
@ MPG123_INT_OVERFLOW
Definition: mpg123.h:572
@ MPG123_BAD_HANDLE
Definition: mpg123.h:539
@ MPG123_RESYNC_FAIL
Definition: mpg123.h:557
@ MPG123_BAD_OUTFORMAT
Definition: mpg123.h:530
@ MPG123_NO_TIMEOUT
Definition: mpg123.h:550
@ MPG123_INDEX_FAIL
Definition: mpg123.h:565
@ MPG123_BAD_BUFFER
Definition: mpg123.h:535
@ MPG123_ERR
Definition: mpg123.h:528
@ MPG123_NULL_POINTER
Definition: mpg123.h:562
@ MPG123_BAD_RVA
Definition: mpg123.h:541
@ MPG123_BAD_FILE
Definition: mpg123.h:551
@ MPG123_ERR_READER
Definition: mpg123.h:547
@ MPG123_NO_SEEK_FROM_END
Definition: mpg123.h:548
@ MPG123_NOT_INITIALIZED
Definition: mpg123.h:537
@ MPG123_OUT_OF_MEM
Definition: mpg123.h:536
@ MPG123_NULL_BUFFER
Definition: mpg123.h:560
@ MPG123_OUT_OF_SYNC
Definition: mpg123.h:556
@ MPG123_NO_SPACE
Definition: mpg123.h:543
@ MPG123_ERR_NULL
Definition: mpg123.h:546
@ MPG123_BAD_TYPES
Definition: mpg123.h:544
@ MPG123_LFS_OVERFLOW
Definition: mpg123.h:571
@ MPG123_NEW_FORMAT
Definition: mpg123.h:526
@ MPG123_BAD_KEY
Definition: mpg123.h:563
@ MPG123_NO_READER
Definition: mpg123.h:553
@ MPG123_BAD_CUSTOM_IO
Definition: mpg123.h:570
@ MPG123_BAD_WHENCE
Definition: mpg123.h:549
@ MPG123_BAD_ALIGN
Definition: mpg123.h:559
@ MPG123_NO_BUFFERS
Definition: mpg123.h:540
@ MPG123_NO_INDEX
Definition: mpg123.h:564
@ MPG123_DONE
Definition: mpg123.h:525
@ MPG123_BAD_DECODER_SETUP
Definition: mpg123.h:566
@ MPG123_NO_RELSEEK
Definition: mpg123.h:561
@ MPG123_NO_GAPLESS
Definition: mpg123.h:542
@ MPG123_BAD_INDEX_PAR
Definition: mpg123.h:555
@ MPG123_BAD_VALUE
Definition: mpg123.h:568
@ MPG123_MISSING_FEATURE
Definition: mpg123.h:567
@ MPG123_BAD_BAND
Definition: mpg123.h:545
@ MPG123_OK
Definition: mpg123.h:529
@ MPG123_BAD_FLOAT
Definition: mpg123.h:573
@ MPG123_BAD_RATE
Definition: mpg123.h:532
@ MPG123_BAD_DECODER
Definition: mpg123.h:538
@ MPG123_NO_8BIT
Definition: mpg123.h:558
#define MPG123_EXPORT
Definition: mpg123.h:45
ssize_t mpg123_ssize_t
Definition: mpg123.h:104
unsigned int mpg123_libversion(unsigned int *patch)
MPG123_EXPORT void mpg123_free(void *ptr)
mpg123_param_flags
Definition: mpg123.h:315
MPG123_EXPORT mpg123_handle * mpg123_new(const char *decoder, int *error)
MPG123_EXPORT void mpg123_delete(mpg123_handle *mh)
const char * mpg123_distversion(unsigned int *major, unsigned int *minor, unsigned int *patch)
MPG123_EXPORT int mpg123_feature2(int key)
MPG123_EXPORT int mpg123_getparam(mpg123_handle *mh, enum mpg123_parms type, long *value, double *fvalue)
struct mpg123_handle_struct mpg123_handle
Definition: mpg123.h:222
mpg123_parms
Definition: mpg123.h:285
mpg123_param_rva
Definition: mpg123.h:376
mpg123_feature_set
Definition: mpg123.h:445
MPG123_EXPORT int mpg123_getparam2(mpg123_handle *mh, int type, long *value, double *fvalue)
MPG123_EXPORT int mpg123_param2(mpg123_handle *mh, int type, long value, double fvalue)
MPG123_EXPORT void mpg123_exit(void)
MPG123_EXPORT int mpg123_param(mpg123_handle *mh, enum mpg123_parms type, long value, double fvalue)
MPG123_EXPORT int mpg123_init(void)
MPG123_EXPORT int mpg123_feature(const enum mpg123_feature_set key)
@ MPG123_IGNORE_STREAMLENGTH
Definition: mpg123.h:329
@ MPG123_FORCE_MONO
Definition: mpg123.h:316
@ MPG123_FUZZY
Definition: mpg123.h:326
@ MPG123_FORCE_FLOAT
Definition: mpg123.h:327
@ MPG123_QUIET
Definition: mpg123.h:322
@ MPG123_NO_RESYNC
Definition: mpg123.h:324
@ MPG123_IGNORE_INFOFRAME
Definition: mpg123.h:331
@ MPG123_MONO_LEFT
Definition: mpg123.h:317
@ MPG123_FORCE_8BIT
Definition: mpg123.h:321
@ MPG123_BIG_ENDIAN
Definition: mpg123.h:348
@ MPG123_PICTURE
Definition: mpg123.h:333
@ MPG123_SEEKBUFFER
Definition: mpg123.h:325
@ MPG123_GAPLESS
Definition: mpg123.h:323
@ MPG123_FORCE_STEREO
Definition: mpg123.h:320
@ MPG123_NO_PEEK_END
Definition: mpg123.h:334
@ MPG123_STORE_RAW_ID3
Definition: mpg123.h:341
@ MPG123_MONO_RIGHT
Definition: mpg123.h:318
@ MPG123_FORCE_SEEKABLE
Definition: mpg123.h:340
@ MPG123_AUTO_RESAMPLE
Definition: mpg123.h:332
@ MPG123_NO_READAHEAD
Definition: mpg123.h:349
@ MPG123_PLAIN_ID3TEXT
Definition: mpg123.h:328
@ MPG123_FORCE_ENDIAN
Definition: mpg123.h:342
@ MPG123_FLOAT_FALLBACK
Definition: mpg123.h:356
@ MPG123_MONO_MIX
Definition: mpg123.h:319
@ MPG123_SKIP_ID3V2
Definition: mpg123.h:330
@ MPG123_NO_FRANKENSTEIN
Definition: mpg123.h:364
@ MPG123_VERBOSE
Definition: mpg123.h:286
@ MPG123_UPSPEED
Definition: mpg123.h:293
@ MPG123_TIMEOUT
Definition: mpg123.h:299
@ MPG123_DOWNSPEED
Definition: mpg123.h:292
@ MPG123_START_FRAME
Definition: mpg123.h:294
@ MPG123_DOWN_SAMPLE
Definition: mpg123.h:290
@ MPG123_RESYNC_LIMIT
Definition: mpg123.h:301
@ MPG123_INDEX_SIZE
Definition: mpg123.h:302
@ MPG123_ADD_FLAGS
Definition: mpg123.h:288
@ MPG123_OUTSCALE
Definition: mpg123.h:298
@ MPG123_FREEFORMAT_SIZE
Definition: mpg123.h:306
@ MPG123_ICY_INTERVAL
Definition: mpg123.h:296
@ MPG123_FEEDPOOL
Definition: mpg123.h:304
@ MPG123_FEEDBUFFER
Definition: mpg123.h:305
@ MPG123_REMOVE_FLAGS
Definition: mpg123.h:300
@ MPG123_FLAGS
Definition: mpg123.h:287
@ MPG123_FORCE_RATE
Definition: mpg123.h:289
@ MPG123_DECODE_FRAMES
Definition: mpg123.h:295
@ MPG123_PREFRAMES
Definition: mpg123.h:303
@ MPG123_RVA
Definition: mpg123.h:291
@ MPG123_RVA_MIX
Definition: mpg123.h:378
@ MPG123_RVA_ALBUM
Definition: mpg123.h:379
@ MPG123_RVA_MAX
Definition: mpg123.h:380
@ MPG123_RVA_OFF
Definition: mpg123.h:377
@ MPG123_FEATURE_INDEX
Definition: mpg123.h:450
@ MPG123_FEATURE_TIMEOUT_READ
Definition: mpg123.h:459
@ MPG123_FEATURE_DECODE_LAYER3
Definition: mpg123.h:454
@ MPG123_FEATURE_DECODE_NTOM
Definition: mpg123.h:457
@ MPG123_FEATURE_EQUALIZER
Definition: mpg123.h:460
@ MPG123_FEATURE_MOREINFO
Definition: mpg123.h:461
@ MPG123_FEATURE_PARSE_ID3V2
Definition: mpg123.h:451
@ MPG123_FEATURE_PARSE_ICY
Definition: mpg123.h:458
@ MPG123_FEATURE_OUTPUT_FLOAT32
Definition: mpg123.h:462
@ MPG123_FEATURE_OUTPUT_32BIT
Definition: mpg123.h:449
@ MPG123_FEATURE_OUTPUT_FLOAT64
Definition: mpg123.h:463
@ MPG123_FEATURE_OUTPUT_8BIT
Definition: mpg123.h:447
@ MPG123_FEATURE_ABI_UTF8OPEN
Definition: mpg123.h:446
@ MPG123_FEATURE_DECODE_ACCURATE
Definition: mpg123.h:455
@ MPG123_FEATURE_DECODE_DOWNSAMPLE
Definition: mpg123.h:456
@ MPG123_FEATURE_DECODE_LAYER2
Definition: mpg123.h:453
@ MPG123_FEATURE_OUTPUT_16BIT
Definition: mpg123.h:448
@ MPG123_FEATURE_DECODE_LAYER1
Definition: mpg123.h:452
MPG123_EXPORT int mpg123_open_feed(mpg123_handle *mh)
MPG123_EXPORT int mpg123_feed(mpg123_handle *mh, const unsigned char *in, size_t size)
MPG123_EXPORT int mpg123_close(mpg123_handle *mh)
MPG123_EXPORT int mpg123_decode(mpg123_handle *mh, const unsigned char *inmemory, size_t inmemsize, void *outmemory, size_t outmemsize, size_t *done)
MPG123_EXPORT int mpg123_open64(mpg123_handle *mh, void *iohandle)
MPG123_EXPORT int mpg123_framebyframe_decode64(mpg123_handle *mh, int64_t *num, unsigned char **audio, size_t *bytes)
MPG123_EXPORT int mpg123_decode_frame64(mpg123_handle *mh, int64_t *num, unsigned char **audio, size_t *bytes)
MPG123_EXPORT int mpg123_open(mpg123_handle *mh, const char *path)
MPG123_EXPORT int mpg123_open_fd(mpg123_handle *mh, int fd)
MPG123_EXPORT int mpg123_open_fixed(mpg123_handle *mh, const char *path, int channels, int encoding)
MPG123_EXPORT int mpg123_framedata(mpg123_handle *mh, unsigned long *header, unsigned char **bodydata, size_t *bodybytes)
MPG123_EXPORT int mpg123_open_handle(mpg123_handle *mh, void *iohandle)
MPG123_EXPORT int mpg123_decode_frame(mpg123_handle *mh, off_t *num, unsigned char **audio, size_t *bytes)
MPG123_EXPORT int mpg123_read(mpg123_handle *mh, void *outmemory, size_t outmemsize, size_t *done)
MPG123_EXPORT int mpg123_framebyframe_next(mpg123_handle *mh)
MPG123_EXPORT int mpg123_framebyframe_decode(mpg123_handle *mh, off_t *num, unsigned char **audio, size_t *bytes)
MPG123_EXPORT int64_t mpg123_framepos64(mpg123_handle *mh)
MPG123_EXPORT off_t mpg123_framepos(mpg123_handle *mh)
MPG123_EXPORT size_t mpg123_outblock(mpg123_handle *mh)
MPG123_EXPORT int mpg123_replace_reader_handle(mpg123_handle *mh, mpg123_ssize_t(*r_read)(void *, void *, size_t), off_t(*r_lseek)(void *, off_t, int), void(*cleanup)(void *))
MPG123_EXPORT int mpg123_reader64(mpg123_handle *mh, int(*r_read)(void *, void *, size_t, size_t *), int64_t(*r_lseek)(void *, int64_t, int), void(*cleanup)(void *))
MPG123_EXPORT int mpg123_replace_reader(mpg123_handle *mh, mpg123_ssize_t(*r_read)(int, void *, size_t), off_t(*r_lseek)(int, off_t, int))
MPG123_EXPORT int mpg123_replace_buffer(mpg123_handle *mh, void *data, size_t size)
MPG123_EXPORT char * mpg123_icy2utf8(const char *icy_text)
MPG123_EXPORT int mpg123_same_string(mpg123_string *a, mpg123_string *b)
MPG123_EXPORT int mpg123_grow_string(mpg123_string *sb, size_t news)
MPG123_EXPORT int mpg123_meta_check(mpg123_handle *mh)
MPG123_EXPORT void mpg123_free_string(mpg123_string *sb)
MPG123_EXPORT int mpg123_set_substring(mpg123_string *sb, const char *stuff, size_t from, size_t count)
MPG123_EXPORT int mpg123_store_utf8_2(mpg123_string *sb, int enc, const unsigned char *source, size_t source_size)
mpg123_text_encoding
Definition: mpg123.h:1834
MPG123_EXPORT void mpg123_meta_free(mpg123_handle *mh)
MPG123_EXPORT mpg123_string * mpg123_new_string(const char *val)
MPG123_EXPORT size_t mpg123_strlen(mpg123_string *sb, int utf8)
MPG123_EXPORT int mpg123_resize_string(mpg123_string *sb, size_t news)
MPG123_EXPORT int mpg123_store_utf8(mpg123_string *sb, enum mpg123_text_encoding enc, const unsigned char *source, size_t source_size)
MPG123_EXPORT int mpg123_icy(mpg123_handle *mh, char **icy_meta)
mpg123_id3_enc
Definition: mpg123.h:1854
MPG123_EXPORT int mpg123_add_substring(mpg123_string *sb, const char *stuff, size_t from, size_t count)
MPG123_EXPORT int mpg123_id3(mpg123_handle *mh, mpg123_id3v1 **v1, mpg123_id3v2 **v2)
MPG123_EXPORT int mpg123_set_string(mpg123_string *sb, const char *stuff)
MPG123_EXPORT int mpg123_copy_string(mpg123_string *from, mpg123_string *to)
MPG123_EXPORT int mpg123_add_string(mpg123_string *sb, const char *stuff)
MPG123_EXPORT enum mpg123_text_encoding mpg123_enc_from_id3(unsigned char id3_enc_byte)
MPG123_EXPORT int mpg123_enc_from_id3_2(unsigned char id3_enc_byte)
MPG123_EXPORT void mpg123_delete_string(mpg123_string *sb)
MPG123_EXPORT int mpg123_chomp_string(mpg123_string *sb)
MPG123_EXPORT void mpg123_init_string(mpg123_string *sb)
mpg123_id3_pic_type
Definition: mpg123.h:1933
MPG123_EXPORT int mpg123_id3_raw(mpg123_handle *mh, unsigned char **v1, size_t *v1_size, unsigned char **v2, size_t *v2_size)
MPG123_EXPORT int mpg123_move_string(mpg123_string *from, mpg123_string *to)
@ mpg123_text_cp1252
Definition: mpg123.h:1839
@ mpg123_text_max
Definition: mpg123.h:1849
@ mpg123_text_utf16bom
Definition: mpg123.h:1844
@ mpg123_text_utf16be
Definition: mpg123.h:1845
@ mpg123_text_unknown
Definition: mpg123.h:1835
@ mpg123_text_icy
Definition: mpg123.h:1838
@ mpg123_text_utf16
Definition: mpg123.h:1840
@ mpg123_text_utf8
Definition: mpg123.h:1836
@ mpg123_text_latin1
Definition: mpg123.h:1837
@ mpg123_id3_latin1
Definition: mpg123.h:1855
@ mpg123_id3_utf16be
Definition: mpg123.h:1857
@ mpg123_id3_enc_max
Definition: mpg123.h:1859
@ mpg123_id3_utf16bom
Definition: mpg123.h:1856
@ mpg123_id3_utf8
Definition: mpg123.h:1858
@ mpg123_id3_pic_publisher_logo
Definition: mpg123.h:1954
@ mpg123_id3_pic_performance
Definition: mpg123.h:1949
@ mpg123_id3_pic_leaflet
Definition: mpg123.h:1939
@ mpg123_id3_pic_recording
Definition: mpg123.h:1948
@ mpg123_id3_pic_back_cover
Definition: mpg123.h:1938
@ mpg123_id3_pic_video
Definition: mpg123.h:1950
@ mpg123_id3_pic_conductor
Definition: mpg123.h:1943
@ mpg123_id3_pic_media
Definition: mpg123.h:1940
@ mpg123_id3_pic_lead
Definition: mpg123.h:1941
@ mpg123_id3_pic_artist
Definition: mpg123.h:1942
@ mpg123_id3_pic_artist_logo
Definition: mpg123.h:1953
@ mpg123_id3_pic_orchestra
Definition: mpg123.h:1944
@ mpg123_id3_pic_icon
Definition: mpg123.h:1935
@ mpg123_id3_pic_composer
Definition: mpg123.h:1945
@ mpg123_id3_pic_other
Definition: mpg123.h:1934
@ mpg123_id3_pic_location
Definition: mpg123.h:1947
@ mpg123_id3_pic_illustration
Definition: mpg123.h:1952
@ mpg123_id3_pic_front_cover
Definition: mpg123.h:1937
@ mpg123_id3_pic_lyricist
Definition: mpg123.h:1946
@ mpg123_id3_pic_fish
Definition: mpg123.h:1951
@ mpg123_id3_pic_other_icon
Definition: mpg123.h:1936
MPG123_EXPORT int mpg123_format2(mpg123_handle *mh, long rate, int channels, int encodings)
MPG123_EXPORT int mpg123_format_all(mpg123_handle *mh)
MPG123_EXPORT int mpg123_format_none(mpg123_handle *mh)
mpg123_channelcount
Definition: mpg123.h:667
MPG123_EXPORT void mpg123_encodings(const int **list, size_t *number)
MPG123_EXPORT void mpg123_rates(const long **list, size_t *number)
MPG123_EXPORT int mpg123_format(mpg123_handle *mh, long rate, int channels, int encodings)
MPG123_EXPORT int mpg123_getformat2(mpg123_handle *mh, long *rate, int *channels, int *encoding, int clear_flag)
MPG123_EXPORT int mpg123_format_support(mpg123_handle *mh, long rate, int encoding)
MPG123_EXPORT int mpg123_getformat(mpg123_handle *mh, long *rate, int *channels, int *encoding)
MPG123_EXPORT int mpg123_encsize(int encoding)
@ MPG123_STEREO
Definition: mpg123.h:669
@ MPG123_MONO
Definition: mpg123.h:668
MPG123_EXPORT int mpg123_set_index(mpg123_handle *mh, off_t *offsets, off_t step, size_t fill)
MPG123_EXPORT int mpg123_index64(mpg123_handle *mh, int64_t **offsets, int64_t *step, size_t *fill)
MPG123_EXPORT int64_t mpg123_tell64(mpg123_handle *mh)
MPG123_EXPORT off_t mpg123_tell_stream(mpg123_handle *mh)
MPG123_EXPORT int64_t mpg123_tell_stream64(mpg123_handle *mh)
MPG123_EXPORT int64_t mpg123_seek_frame64(mpg123_handle *mh, int64_t frameoff, int whence)
MPG123_EXPORT int64_t mpg123_tellframe64(mpg123_handle *mh)
MPG123_EXPORT int mpg123_set_index64(mpg123_handle *mh, int64_t *offsets, int64_t step, size_t fill)
MPG123_EXPORT off_t mpg123_tellframe(mpg123_handle *mh)
MPG123_EXPORT off_t mpg123_tell(mpg123_handle *mh)
MPG123_EXPORT off_t mpg123_feedseek(mpg123_handle *mh, off_t sampleoff, int whence, off_t *input_offset)
MPG123_EXPORT off_t mpg123_timeframe(mpg123_handle *mh, double sec)
MPG123_EXPORT int64_t mpg123_feedseek64(mpg123_handle *mh, int64_t sampleoff, int whence, int64_t *input_offset)
MPG123_EXPORT off_t mpg123_seek(mpg123_handle *mh, off_t sampleoff, int whence)
MPG123_EXPORT int mpg123_position(mpg123_handle *mh, off_t INT123_frame_offset, off_t buffered_bytes, off_t *current_frame, off_t *frames_left, double *current_seconds, double *seconds_left)
MPG123_EXPORT off_t mpg123_seek_frame(mpg123_handle *mh, off_t frameoff, int whence)
MPG123_EXPORT int mpg123_index(mpg123_handle *mh, off_t **offsets, off_t *step, size_t *fill)
MPG123_EXPORT int64_t mpg123_seek64(mpg123_handle *mh, int64_t sampleoff, int whence)
MPG123_EXPORT int64_t mpg123_timeframe64(mpg123_handle *mh, double sec)
mpg123_mode
Definition: mpg123.h:1444
mpg123_version
Definition: mpg123.h:1435
MPG123_EXPORT int mpg123_set_filesize64(mpg123_handle *mh, int64_t size)
MPG123_EXPORT int mpg123_scan(mpg123_handle *mh)
MPG123_EXPORT int mpg123_info(mpg123_handle *mh, struct mpg123_frameinfo *mi)
MPG123_EXPORT int64_t mpg123_framelength64(mpg123_handle *mh)
MPG123_EXPORT int mpg123_spf(mpg123_handle *mh)
MPG123_EXPORT int mpg123_getstate2(mpg123_handle *mh, int key, long *val, double *fval)
MPG123_EXPORT double mpg123_tpf(mpg123_handle *mh)
MPG123_EXPORT off_t mpg123_length(mpg123_handle *mh)
mpg123_vbr
Definition: mpg123.h:1428
MPG123_EXPORT int mpg123_info2(mpg123_handle *mh, struct mpg123_frameinfo2 *mi)
MPG123_EXPORT off_t mpg123_framelength(mpg123_handle *mh)
MPG123_EXPORT int mpg123_set_moreinfo(mpg123_handle *mh, struct mpg123_moreinfo *mi)
MPG123_EXPORT int mpg123_set_filesize(mpg123_handle *mh, off_t size)
MPG123_EXPORT long mpg123_clip(mpg123_handle *mh)
mpg123_state
Definition: mpg123.h:1649
mpg123_flags
Definition: mpg123.h:1453
MPG123_EXPORT int64_t mpg123_length64(mpg123_handle *mh)
MPG123_EXPORT int mpg123_getstate(mpg123_handle *mh, enum mpg123_state key, long *val, double *fval)
MPG123_EXPORT size_t mpg123_safe_buffer(void)
@ MPG123_M_MONO
Definition: mpg123.h:1448
@ MPG123_M_DUAL
Definition: mpg123.h:1447
@ MPG123_M_JOINT
Definition: mpg123.h:1446
@ MPG123_M_STEREO
Definition: mpg123.h:1445
@ MPG123_2_0
Definition: mpg123.h:1437
@ MPG123_1_0
Definition: mpg123.h:1436
@ MPG123_2_5
Definition: mpg123.h:1438
@ MPG123_CBR
Definition: mpg123.h:1429
@ MPG123_ABR
Definition: mpg123.h:1431
@ MPG123_VBR
Definition: mpg123.h:1430
@ MPG123_ACCURATE
Definition: mpg123.h:1650
@ MPG123_BUFFERFILL
Definition: mpg123.h:1651
@ MPG123_DEC_DELAY
Definition: mpg123.h:1656
@ MPG123_ENC_DELAY
Definition: mpg123.h:1654
@ MPG123_FRANKENSTEIN
Definition: mpg123.h:1652
@ MPG123_ENC_PADDING
Definition: mpg123.h:1655
@ MPG123_FRESH_DECODER
Definition: mpg123.h:1653
@ MPG123_PRIVATE
Definition: mpg123.h:1456
@ MPG123_COPYRIGHT
Definition: mpg123.h:1455
@ MPG123_CRC
Definition: mpg123.h:1454
@ MPG123_ORIGINAL
Definition: mpg123.h:1457
MPG123_EXPORT int mpg123_getvolume(mpg123_handle *mh, double *base, double *really, double *rva_db)
MPG123_EXPORT int mpg123_reset_eq(mpg123_handle *mh)
MPG123_EXPORT double mpg123_geteq2(mpg123_handle *mh, int channel, int band)
MPG123_EXPORT int mpg123_eq2(mpg123_handle *mh, int channel, int band, double val)
MPG123_EXPORT int mpg123_volume_change(mpg123_handle *mh, double change)
MPG123_EXPORT int mpg123_eq_change(mpg123_handle *mh, int channel, int a, int b, double db)
MPG123_EXPORT int mpg123_volume_change_db(mpg123_handle *mh, double db)
MPG123_EXPORT int mpg123_eq_bands(mpg123_handle *mh, int channel, int a, int b, double factor)
MPG123_EXPORT double mpg123_geteq(mpg123_handle *mh, enum mpg123_channels channel, int band)
MPG123_EXPORT int mpg123_volume(mpg123_handle *mh, double vol)
MPG123_EXPORT int mpg123_eq(mpg123_handle *mh, enum mpg123_channels channel, int band, double val)
mpg123_channels
Definition: mpg123.h:1288
@ MPG123_LEFT
Definition: mpg123.h:1289
@ MPG123_RIGHT
Definition: mpg123.h:1290
@ MPG123_LR
Definition: mpg123.h:1291
void cleanup(mpg123_handle *mh, out123_handle *ao)
enum mpg123_mode mode
Definition: mpg123.h:1467
enum mpg123_vbr vbr
Definition: mpg123.h:1474
enum mpg123_flags flags
Definition: mpg123.h:1470
enum mpg123_version version
Definition: mpg123.h:1464
unsigned char genre
Definition: mpg123.h:2009
mpg123_string * genre
Definition: mpg123.h:1982
size_t texts
Definition: mpg123.h:1989
mpg123_string * title
Definition: mpg123.h:1978
mpg123_text * text
Definition: mpg123.h:1988
mpg123_string * comment
Definition: mpg123.h:1983
mpg123_string * artist
Definition: mpg123.h:1979
mpg123_string * year
Definition: mpg123.h:1981
size_t comments
Definition: mpg123.h:1987
unsigned char version
Definition: mpg123.h:1977
mpg123_text * comment_list
Definition: mpg123.h:1986
size_t pictures
Definition: mpg123.h:1994
mpg123_picture * picture
Definition: mpg123.h:1992
mpg123_string * album
Definition: mpg123.h:1980
mpg123_text * extra
Definition: mpg123.h:1990
size_t extras
Definition: mpg123.h:1991
int mainbits[2][2]
Definition: mpg123.h:1511
int preflag[2][2]
Definition: mpg123.h:1508
int scalefac_scale[2][2]
Definition: mpg123.h:1507
int mixed[2][2]
Definition: mpg123.h:1510
int sub_gain[2][2][3]
Definition: mpg123.h:1506
int sfbits[2][2]
Definition: mpg123.h:1512
int big_values[2][2]
Definition: mpg123.h:1505
int qss[2][2]
Definition: mpg123.h:1504
int blocktype[2][2]
Definition: mpg123.h:1509
double sfb_s[2][2][3 *13]
Definition: mpg123.h:1503
double xr[2][2][576]
Definition: mpg123.h:1501
int scfsi[2]
Definition: mpg123.h:1513
double sfb[2][2][22]
Definition: mpg123.h:1502
mpg123_string description
Definition: mpg123.h:1964
unsigned char * data
Definition: mpg123.h:1967
mpg123_string mime_type
Definition: mpg123.h:1965
size_t size
Definition: mpg123.h:1966
char * p
Definition: mpg123.h:1704
size_t fill
Definition: mpg123.h:1706
size_t size
Definition: mpg123.h:1705
mpg123_string text
Definition: mpg123.h:1928
mpg123_string description
Definition: mpg123.h:1927
Hopefully valid HTML! Valid CSS!