Function panning::stereo::pan [] [src]

pub fn pan(pan: f32) -> [f32; 2]

Return the amp for left and right channels according to a given pan between -1.0 and 1.0. pan is assumed to always be between -1.0 and 1.0 (L and R) and will not perform any checks. The minimum and maximum amplitude of each channel will be between 0.0 and 1.0 respectively. A centered pan (0.0) will leave both channels at -3db (0.708). A hard pan to either side will result in the weighted channel at 0db (1.0).