pub fn step_frame<'a, A, V>(&'a mut self, audio: &mut A, video: &mut V)
    where
        A: AudioDevice,
        V: VideoDevice,
    {
        let mut frame_happened = false;
        while !frame_happened {
            let cpucycles = self.cpu.step();
            let m = &mut self.cpu.mem;
            for _ in 0..cpucycles * 3 {
                frame_happened = self.ppu.step(m, video) || frame_happened;
            }
            for _ in 0..cpucycles {
                self.apu.step(m, audio);
            }
        }
    }
/// Advance the console until the next frame.
/// 
/// Unlike the other step methods, this is not based on timing, but
/// based on waiting until the ppu actually generates a video frame.
/// This is more useful for applications that want to do something
/// at the start of every frame, like playing the next frame of input
/// from a recorded script, or things like that.
Advance the console until the next frame.
Unlike the other step methods, this is not based on timing, but
based on waiting until the ppu actually generates a video frame.
This is more useful for applications that want to do something
at the start of every frame, like playing the next frame of input
from a recorded script, or things like that.
Advance the console until the next frame . Unlike the other step methods this is not based on timing but based on waiting until the ppu actually generates a video frame . This is more useful for applications that want to do something at the start of every frame like playing the next frame of input from a recorded script or things like that .
pub fn step_frame<'a, A, V>(&'a mut self, audio: &mut A, video: &mut V)
    where
        A: AudioDevice,
        V: VideoDevice,
    {
        let mut frame_happened = false;
        while !frame_happened {
            let cpucycles = self.cpu.step();
            let m = &mut self.cpu.mem;
            for _ in 0..cpucycles * 3 {
                frame_happened = self.ppu.step(m, video) || frame_happened;
            }
            for _ in 0..cpucycles {
                self.apu.step(m, audio);
            }
        }
    }
pub fn step_frame < ' a , A , V > ( & ' a mut self , audio : & mut A , video : & mut V ) where A : AudioDevice , V : VideoDevice , { let mut frame_happened = false ; while ! frame_happened { let cpucycles = self . cpu . step ( ) ; let m = & mut self . cpu . mem ; for _ in 0 .. cpucycles * 3 { frame_happened = self . ppu . step ( m , video ) || frame_happened ; } for _ in 0 .. cpucycles { self . apu . step ( m , audio ) ; } } }
Advance the console until the next frame.
Advance the console until the next frame .
&'a mut self
audio
&mut A
video
&mut V
&'a mut self
audio
&mut A
video
&mut V