fn next(&mut self) -> Option<Self::Item> {
        self.sample_count += 1;
        if self.sample_count > self.duration { return None; }

        self.sample_clock = (self.sample_clock + 1.) % self.sample_rate;
        Some((self.sample_clock * self.frequency * 2. * PI / self.sample_rate).sin())
    }
// The source is removed from the AudioMixer if/when the iterator returns None.
The source is removed from the AudioMixer if/when the iterator returns None.
The source is removed from the AudioMixer if / when the iterator returns None .
fn next(&mut self) -> Option<Self::Item> {
        self.sample_count += 1;
        if self.sample_count > self.duration { return None; }
        self.sample_clock = (self.sample_clock + 1.) % self.sample_rate;
        Some((self.sample_clock * self.frequency * 2. * PI / self.sample_rate).sin())
    }
fn next ( & mut self ) -> Option < Self :: Item > { self . sample_count += 1 ; if self . sample_count > self . duration { return None ; } self . sample_clock = ( self . sample_clock + 1. ) % self . sample_rate ; Some ( ( self . sample_clock * self . frequency * 2. * PI / self . sample_rate ) . sin ( ) ) }
The source is removed from the AudioMixer if/when the iterator returns None.
The source is removed from the AudioMixer if / when the iterator returns None .
&mut self
&mut self