|
Defines |
| #define | NORMFACT (float)0x8000 |
| #define | MAXSAMPLE (float)0x7FFF |
| #define | MAXSAMPLEC (char)0x7F |
| #define | QUALITY 0 |
| #define | MIN(a, b) ((a) < (b) ? (a) : (b)) |
| #define | MAX(a, b) ((a) > (b) ? (a) : (b)) |
| #define | resample_buffer(a, b, c) a > b ? ((a / 1000) / 2) * c : ((b / 1000) / 2) * c |
Functions |
| switch_status_t | switch_resample_create (switch_audio_resampler_t **new_resampler, int from_rate, switch_size_t from_size, int to_rate, uint32_t to_size, switch_memory_pool_t *pool) |
| | Prepare a new resampler handle.
|
| uint32_t | switch_resample_process (switch_audio_resampler_t *resampler, float *src, int srclen, float *dst, uint32_t dstlen, int last) |
| | Resample one float buffer into another using specifications of a given handle.
|
| void | switch_resample_destroy (switch_audio_resampler_t **resampler) |
| | Destroy an existing resampler handle.
|
| switch_size_t | switch_float_to_short (float *f, short *s, switch_size_t len) |
| | Convert an array of floats to an array of shorts.
|
| int | switch_char_to_float (char *c, float *f, int len) |
| | Convert an array of chars to an array of floats.
|
| int | switch_float_to_char (float *f, char *c, int len) |
| | Convert an array of floats to an array of chars.
|
| int | switch_short_to_float (short *s, float *f, int len) |
| | Convert an array of shorts to an array of floats.
|
| void | switch_swap_linear (int16_t *buf, int len) |
| | Perform a byteswap on a buffer of 16 bit samples.
|
| void | switch_generate_sln_silence (int16_t *data, uint32_t samples, uint32_t divisor) |
| | Generate static noise.
|
| uint32_t | switch_merge_sln (int16_t *data, uint32_t samples, int16_t *other_data, uint32_t other_samples) |
| void | switch_change_sln_volume (int16_t *data, uint32_t samples, int32_t vol) |
| | Change the volume of a signed linear audio frame.
|