pub fn new(amplitude: f32, frequency: f32) -> Self {
        SineWave {
            amplitude,
            format: AudioFormat::default(),
            phase: 0.0,
            frequency,
        }
    }
/// Construct a new sine wave generator with the given amplitude and frequency.
///
/// Uses [`AudioFormat::default()`](crate::AudioFormat::default) as the format.
///
/// # Arguments
///
/// * `amplitude` -- The peak value of samples generated by the generator.
/// * `frequency` -- The frequency of the wave generated, in Hz.
Construct a new sine wave generator with the given amplitude and frequency.
Construct a new sine wave generator with the given amplitude and frequency .
pub fn new(amplitude: f32, frequency: f32) -> Self {
        SineWave {
            amplitude,
            format: AudioFormat::default(),
            phase: 0.0,
            frequency,
        }
    }
pub fn new ( amplitude : f32 , frequency : f32 ) -> Self { SineWave { amplitude , format : AudioFormat :: default ( ) , phase : 0.0 , frequency , } }
Construct a new sine wave generator with the given amplitude and frequency.
Construct a new sine wave generator with the given amplitude and frequency .
amplitude
f32
frequency
f32
amplitude
f32
frequency
f32