public void FrameAdvance(bool render, bool renderSound) { Cpu.Debug = Tracer.Enabled; Frame++; _isLag = true; PSG.BeginFrame(Cpu.TotalExecutedCycles); if (Cpu.Debug && Cpu.Logger == null) // TODO, lets not do this on each frame. But lets refactor CoreComm/CoreComm first { Cpu.Logger = (s) => Tracer.Put(s); } byte temp_ret1 = ControllerDeck.ReadPort1(Controller, true, true); byte temp_ret2 = ControllerDeck.ReadPort2(Controller, true, true); bool Int_pending = (!temp_ret1.Bit(4)) | (!temp_ret2.Bit(4)); VDP.ExecuteFrame(Int_pending); PSG.EndFrame(Cpu.TotalExecutedCycles); if (_isLag) { _lagCount++; } }
public void FrameAdvance(bool render, bool renderSound) { Frame++; isLag = true; PSG.BeginFrame(Cpu.TotalExecutedCycles); VDP.ExecuteFrame(); PSG.EndFrame(Cpu.TotalExecutedCycles); if (isLag) { LagCount++; } }
public void FrameAdvance(bool render, bool renderSound) { Cpu.Debug = Tracer.Enabled; Frame++; _isLag = true; PSG.BeginFrame(Cpu.TotalExecutedCycles); if (Cpu.Debug && Cpu.Logger == null) // TODO, lets not do this on each frame. But lets refactor CoreComm/CoreComm first { Cpu.Logger = (s) => Tracer.Put(s); } VDP.ExecuteFrame(); PSG.EndFrame(Cpu.TotalExecutedCycles); if (_isLag) { _lagCount++; } }