Enumerations | |
| enum | mpg123_enc_enum { MPG123_ENC_8 = 0x00f, MPG123_ENC_16 = 0x040, MPG123_ENC_32 = 0x100, MPG123_ENC_SIGNED = 0x080, MPG123_ENC_FLOAT = 0x800, MPG123_ENC_SIGNED_16 = (MPG123_ENC_16|MPG123_ENC_SIGNED|0x10), MPG123_ENC_UNSIGNED_16 = (MPG123_ENC_16|0x20), MPG123_ENC_UNSIGNED_8 = 0x01, MPG123_ENC_SIGNED_8 = (MPG123_ENC_SIGNED|0x02), MPG123_ENC_ULAW_8 = 0x04, MPG123_ENC_ALAW_8 = 0x08, MPG123_ENC_SIGNED_32 = MPG123_ENC_32|MPG123_ENC_SIGNED|0x10, MPG123_ENC_UNSIGNED_32 = MPG123_ENC_32|0x20, MPG123_ENC_FLOAT_32 = 0x200, MPG123_ENC_FLOAT_64 = 0x400, MPG123_ENC_ANY } |
| enum | mpg123_channelcount { MPG123_MONO = 1, MPG123_STEREO = 2 } |
Functions | |
| void | mpg123_rates (const long **list, size_t *number) |
| void | mpg123_encodings (const int **list, size_t *number) |
| int | mpg123_format_none (mpg123_handle *mh) |
| int | mpg123_format_all (mpg123_handle *mh) |
| int | mpg123_format (mpg123_handle *mh, long rate, int channels, int encodings) |
| int | mpg123_format_support (mpg123_handle *mh, long rate, int encoding) |
| int | mpg123_getformat (mpg123_handle *mh, long *rate, int *channels, int *encoding) |
| enum mpg123_enc_enum |
16 or 8 bits, signed or unsigned... all flags fit into 15 bits and are designed to have meaningful binary AND/OR. Adding float and 32bit int definitions for experimental fun. Only 32bit (and possibly 64bit) float is somewhat there with a dedicated library build.
| enum mpg123_channelcount |
| void mpg123_rates | ( | const long ** | list, | |
| size_t * | number | |||
| ) |
An array of supported standard sample rates These are possible native sample rates of MPEG audio files. You can still force mpg123 to resample to a different one, but by default you will only get audio in one of these samplings.
| list | Store a pointer to the sample rates array there. | |
| number | Store the number of sample rates there. |
| void mpg123_encodings | ( | const int ** | list, | |
| size_t * | number | |||
| ) |
An array of supported audio encodings. An audio encoding is one of the fully qualified members of mpg123_enc_enum (MPG123_ENC_SIGNED_16, not MPG123_SIGNED).
| list | Store a pointer to the encodings array there. | |
| number | Store the number of encodings there. |
| int mpg123_format_none | ( | mpg123_handle * | mh | ) |
Configure a mpg123 handle to accept no output format at all, use before specifying supported formats with mpg123_format
| int mpg123_format_all | ( | mpg123_handle * | mh | ) |
Configure mpg123 handle to accept all formats (also any custom rate you may set) -- this is default.
| int mpg123_format | ( | mpg123_handle * | mh, | |
| long | rate, | |||
| int | channels, | |||
| int | encodings | |||
| ) |
Set the audio format support of a mpg123_handle in detail:
| mh | audio decoder handle | |
| rate | The sample rate value (in Hertz). | |
| channels | A combination of MPG123_STEREO and MPG123_MONO. | |
| encodings | A combination of accepted encodings for rate and channels, p.ex MPG123_ENC_SIGNED16 | MPG123_ENC_ULAW_8 (or 0 for no support). Please note that some encodings may not be supported in the library build and thus will be ignored here. |
| int mpg123_format_support | ( | mpg123_handle * | mh, | |
| long | rate, | |||
| int | encoding | |||
| ) |
Check to see if a specific format at a specific rate is supported by mpg123_handle.
| int mpg123_getformat | ( | mpg123_handle * | mh, | |
| long * | rate, | |||
| int * | channels, | |||
| int * | encoding | |||
| ) |
Get the current output format written to the addresses givenr.
1.5.4