Result Tracker::TryResync(Result lastResult,bool excludeFrame) const { NST_VERIFY( NES_SUCCEEDED(lastResult) ); if (NES_SUCCEEDED(lastResult) && lastResult != RESULT_NOP) Resync( excludeFrame ); return lastResult; }
Result Video::SetRenderState(const RenderState& state) throw() { const Result result = emulator.renderer.SetState( state ); if (NES_SUCCEEDED(result) && result != RESULT_NOP) emulator.UpdateColorMode(); return result; }
Result Patcher::Load(std::istream& patchStream,std::istream& srcStream) { Result result = Load( patchStream ); if (NES_SUCCEEDED(result)) { result = Test( srcStream ); if (NES_FAILED(result)) Destroy(); } return result; }
Result Machine::SetMode(const Mode mode) throw() { if (mode == GetMode()) return RESULT_NOP; Result result = Power( false ); if (NES_SUCCEEDED(result)) { emulator.SwitchMode(); if (result != RESULT_NOP) result = Power( true ); } return result; }