aboutsummaryrefslogtreecommitdiff
path: root/source/fxemu.h
diff options
context:
space:
mode:
authorTwinaphex2017-06-18 18:41:06 +0200
committerGitHub2017-06-18 18:41:06 +0200
commit1aecedc999445e9a27e04f665fd562b576775d08 (patch)
treec526c7d332be548a42364eea9113b6d33345b840 /source/fxemu.h
parentdc596c886e0ec2728dc353dd7862cdf1e5a5ff44 (diff)
parentbcaf44c511efaad9d803dde9b0fdbb046498c66f (diff)
downloadsnes9x2005-1aecedc999445e9a27e04f665fd562b576775d08.tar.gz
snes9x2005-1aecedc999445e9a27e04f665fd562b576775d08.tar.bz2
snes9x2005-1aecedc999445e9a27e04f665fd562b576775d08.zip
Merge pull request #36 from jamsilva/master
Compatibility fixes.
Diffstat (limited to 'source/fxemu.h')
-rw-r--r--source/fxemu.h27
1 files changed, 13 insertions, 14 deletions
diff --git a/source/fxemu.h b/source/fxemu.h
index 0012c33..3af330c 100644
--- a/source/fxemu.h
+++ b/source/fxemu.h
@@ -6,48 +6,47 @@
#include "snes9x.h"
/* The FxInfo_s structure, the link between the FxEmulator and the Snes Emulator */
-struct FxInit_s
+typedef struct
{
- uint32_t vFlags;
uint8_t* pvRegisters; /* 768 bytes located in the memory at address 0x3000 */
uint32_t nRamBanks; /* Number of 64kb-banks in GSU-RAM/BackupRAM (banks 0x70-0x73) */
uint8_t* pvRam; /* Pointer to GSU-RAM */
uint32_t nRomBanks; /* Number of 32kb-banks in Cart-ROM */
uint8_t* pvRom; /* Pointer to Cart-ROM */
-};
+} FxInit_s;
/* Reset the FxChip */
-extern void FxReset(struct FxInit_s* psFxInfo);
+extern void FxReset(FxInit_s* psFxInfo);
/* Execute until the next stop instruction */
extern int32_t FxEmulate(uint32_t nInstructions);
/* Write access to the cache */
extern void FxCacheWriteAccess(uint16_t vAddress);
-extern void FxFlushCache(); /* Callled when the G flag in SFR is set to zero */
+extern void FxFlushCache(void); /* Called when the G flag in SFR is set to zero */
/* Errors */
-extern int32_t FxGetErrorCode();
-extern int32_t FxGetIllegalAddress();
+extern int32_t FxGetErrorCode(void);
+extern int32_t FxGetIllegalAddress(void);
/* Access to internal registers */
-extern uint32_t FxGetColorRegister();
-extern uint32_t FxGetPlotOptionRegister();
-extern uint32_t FxGetSourceRegisterIndex();
-extern uint32_t FxGetDestinationRegisterIndex();
+extern uint32_t FxGetColorRegister(void);
+extern uint32_t FxGetPlotOptionRegister(void);
+extern uint32_t FxGetSourceRegisterIndex(void);
+extern uint32_t FxGetDestinationRegisterIndex(void);
/* Get the byte currently in the pipe */
-extern uint8_t FxPipe();
+extern uint8_t FxPipe(void);
/* SCBR write seen. We need to update our cached screen pointers */
-extern void fx_dirtySCBR();
+extern void fx_dirtySCBR(void);
/* Update RamBankReg and RAM Bank pointer */
extern void fx_updateRamBank(uint8_t Byte);
/* Option flags */
#define FX_FLAG_ADDRESS_CHECKING 0x01
-#define FX_FLAG_ROM_BUFFER 0x02
+#define FX_FLAG_ROM_BUFFER 0x02
/* Return codes from FxEmulate(), FxStepInto() or FxStepOver() */
#define FX_BREAKPOINT -1