Helpers to convert audio.
More...
|
| void | impact_AudioConvertFrom (const uint8_t *payload, float *output, size_t nSpl, enum impact_SampleFormat fmt) |
| |
| void | impact_AudioConvertTo (const float *input, uint8_t *payload, size_t nSpl, enum impact_SampleFormat fmt) |
| |
| void | impact_StereoToMono (const float *input, float *output, size_t nFrame) |
| |
| void | impact_MonoToStereo (const float *input, float *output, size_t nFrame) |
| |
| void | impact_StereoToMono_Planar (const float *inputL, const float *inputR, float *output, size_t nFrame) |
| |
| void | impact_MonoToStereo_Planar (const float *input, float *outputL, float *outputR, size_t nFrame) |
| |
| void | impact_AudioMonoFromLiveStereo (const uint8_t *payload, float *output) |
| |
| void | impact_AudioMonoToLiveStereo (const float *input, uint8_t *payload) |
| |
Helpers to convert audio in an optimized way
◆ impact_AudioConvertFrom()
| void impact_AudioConvertFrom |
( |
const uint8_t * |
payload, |
|
|
float * |
output, |
|
|
size_t |
nSpl, |
|
|
enum impact_SampleFormat |
fmt |
|
) |
| |
Convert the payload to floating-point array
- Warning
- Output buffer must be 64-byte aligned
- Parameters
-
| payload | the binary raw audio buffer |
| output | audio output buffer (64 byte aligned) |
| nSpl | the number of samples (not frames) |
| fmt | the format of the payload |
◆ impact_AudioConvertTo()
| void impact_AudioConvertTo |
( |
const float * |
input, |
|
|
uint8_t * |
payload, |
|
|
size_t |
nSpl, |
|
|
enum impact_SampleFormat |
fmt |
|
) |
| |
Convert floating-point array to payload
- Warning
- Input buffer must be 64-byte aligned
- Parameters
-
| input | audio input buffer (64 byte aligned) |
| payload | the binary raw audio buffer |
| nSpl | the number of samples (not frames) |
| fmt | the format of the payload |
◆ impact_AudioMonoFromLiveStereo()
| void impact_AudioMonoFromLiveStereo |
( |
const uint8_t * |
payload, |
|
|
float * |
output |
|
) |
| |
Convert Livewire Livestereo payload to floating-point Mono (12 samples)
- Parameters
-
| payload | Livewire Live Stereo raw buffer |
| output | audio output mono buffer (64 byte aligned) |
◆ impact_AudioMonoToLiveStereo()
| void impact_AudioMonoToLiveStereo |
( |
const float * |
input, |
|
|
uint8_t * |
payload |
|
) |
| |
Convert floating-point Mono (12 samples) to Livewire Livestereo payload
- Parameters
-
| input | audio input mono buffer (64 byte aligned) |
| payload | Livewire Live Stereo raw buffer |
◆ impact_MonoToStereo()
| void impact_MonoToStereo |
( |
const float * |
input, |
|
|
float * |
output, |
|
|
size_t |
nFrame |
|
) |
| |
Convert floating-point Mono to Stereo (L,L)
- Warning
- Buffers must be 64-byte aligned
- Parameters
-
| input | audio input mono buffer (64 byte aligned) |
| output | audio output stereo buffer (64 byte aligned) |
| nFrame | the number of frames |
◆ impact_MonoToStereo_Planar()
| void impact_MonoToStereo_Planar |
( |
const float * |
input, |
|
|
float * |
outputL, |
|
|
float * |
outputR, |
|
|
size_t |
nFrame |
|
) |
| |
Convert floating-point Mono to Stereo (planar) (L,L)
- Warning
- Buffers must be 64-byte aligned
- Parameters
-
| input | audio input mono buffer (64 byte aligned) |
| outputL | audio output left buffer (64 byte aligned) |
| outputR | audio output right buffer (64 byte aligned) |
| nFrame | the number of frames |
◆ impact_StereoToMono()
| void impact_StereoToMono |
( |
const float * |
input, |
|
|
float * |
output, |
|
|
size_t |
nFrame |
|
) |
| |
Convert floating-point Stereo to Mono (L+R)/2
- Warning
- Buffers must be 64-byte aligned
- Parameters
-
| input | audio input stereo buffer (64 byte aligned) |
| output | audio output mono buffer (64 byte aligned) |
| nFrame | the number of frames |
◆ impact_StereoToMono_Planar()
| void impact_StereoToMono_Planar |
( |
const float * |
inputL, |
|
|
const float * |
inputR, |
|
|
float * |
output, |
|
|
size_t |
nFrame |
|
) |
| |
Convert floating-point Stereo (planar) to Mono (L+R)/2
- Warning
- Buffers must be 64-byte aligned
- Parameters
-
| inputL | audio input left buffer (64 byte aligned) |
| inputR | audio input right buffer (64 byte aligned) |
| output | audio output mono buffer (64 byte aligned) |
| nFrame | the number of frames |