Function audio_visualizer::util::sine::sine_wave_audio_data_multiple [−][src]
pub fn sine_wave_audio_data_multiple(
frequencies: &[f64],
sampling_rate: u32,
duration_ms: u32
) -> Vec<i16>
Expand description
Like sine_wave_audio_data
but puts multiple sinus waves on top of each other.
Returns a audio signal encoded in 16 bit audio resolution which is the sum of
multiple sine waves on top of each other. The amplitudes will be scaled from
[-1; 1]
to [i16::min_value(); i16::max_value()]
frequency
frequency in Hz for the sinus wavesampling_rate
sampling rate, i.e. 44100Hzduration_ms
duration of the audio data in milliseconds