libsidplayfp 1.0.3
|
00001 /* 00002 * This file is part of libsidplayfp, a SID player engine. 00003 * 00004 * Copyright 2011-2013 Leandro Nini <drfiemost@users.sourceforge.net> 00005 * Copyright 2007-2010 Antti Lankila 00006 * Copyright 2001 Simon White 00007 * 00008 * This program is free software; you can redistribute it and/or modify 00009 * it under the terms of the GNU General Public License as published by 00010 * the Free Software Foundation; either version 2 of the License, or 00011 * (at your option) any later version. 00012 * 00013 * This program is distributed in the hope that it will be useful, 00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00016 * GNU General Public License for more details. 00017 * 00018 * You should have received a copy of the GNU General Public License 00019 * along with this program; if not, write to the Free Software 00020 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 00021 */ 00022 00023 #ifndef C64ENV_H 00024 #define C64ENV_H 00025 00026 #include "sidplayfp/event.h" 00027 00028 #ifdef HAVE_CONFIG_H 00029 # include "config.h" 00030 #endif 00031 00037 class c64env 00038 { 00039 private: 00040 EventContext &m_context; 00041 00042 public: 00043 c64env (EventContext *context) : 00044 m_context (*context) {} 00045 00046 EventContext &context() const { return m_context; } 00047 00048 virtual uint8_t cpuRead(uint_least16_t addr) =0; 00049 virtual void cpuWrite(uint_least16_t addr, uint8_t data) =0; 00050 00051 #ifdef PC64_TESTSUITE 00052 virtual void loadFile(const char *file) =0; 00053 #endif 00054 00055 virtual void interruptIRQ(bool state) = 0; 00056 virtual void interruptNMI() = 0; 00057 virtual void interruptRST() = 0; 00058 00059 virtual void setBA (bool state) = 0; 00060 virtual void lightpen() = 0; 00061 00062 protected: 00063 ~c64env() {} 00064 }; 00065 00066 #endif // C64ENV_H