Skip to main content

add_stereo

Function add_stereo 

Source
fn add_stereo(left: &[f32], right: &[f32], chunk: &mut AudioChunk<'_>)
Expand description

Adds a stereo block onto the chunk’s interleaved frames.

A mono stream gets the two channels averaged, so neither is lost; a stream wider than stereo gets them in its first two channels and nothing in the rest, which keeps whatever other sources added.