project64/Source/Project64-core/Plugins/RSPPlugin.h

82 lines
2.1 KiB
C
Raw Normal View History

2016-01-27 09:11:59 +00:00
#pragma once
#include <Project64-core/Plugins/PluginBase.h>
class CRSP_Plugin : public CPlugin
{
2022-10-10 00:22:17 +00:00
typedef struct
{
// Menu
// Items should have an ID between 5001 and 5100
2016-01-27 09:11:59 +00:00
void * hRSPMenu;
2022-10-10 00:22:17 +00:00
void(CALL * ProcessMenuItem)(int32_t ID);
2016-01-27 09:11:59 +00:00
// Breakpoints
2016-01-27 09:11:59 +00:00
int32_t UseBPoints;
char BPPanelName[20];
2022-10-10 00:22:17 +00:00
void(CALL * Add_BPoint)(void);
void(CALL * CreateBPPanel)(void);
void(CALL * HideBPPanel)(void);
void(CALL * PaintBPPanel)(void);
void(CALL * ShowBPPanel)(void);
void(CALL * RefreshBpoints)(void * hList);
void(CALL * RemoveBpoint)(void * hList, int32_t index);
void(CALL * RemoveAllBpoint)(void);
2016-01-27 09:11:59 +00:00
// RSP command window
2022-10-10 00:22:17 +00:00
void(CALL * Enter_RSP_Commands_Window)(void);
2016-01-27 09:11:59 +00:00
} RSPDEBUG_INFO;
2022-10-10 00:22:17 +00:00
typedef struct
{
void(CALL * UpdateBreakPoints)(void);
void(CALL * UpdateMemory)(void);
void(CALL * UpdateR4300iRegisters)(void);
void(CALL * Enter_BPoint_Window)(void);
void(CALL * Enter_R4300i_Commands_Window)(void);
void(CALL * Enter_R4300i_Register_Window)(void);
void(CALL * Enter_RSP_Commands_Window)(void);
void(CALL * Enter_Memory_Window)(void);
2016-01-27 09:11:59 +00:00
} DEBUG_INFO;
public:
CRSP_Plugin(void);
~CRSP_Plugin();
bool Initiate(CPlugins * Plugins, CN64System * System);
2022-10-10 00:22:17 +00:00
uint32_t(CALL * DoRspCycles)(uint32_t);
void(CALL * EnableDebugging)(int32_t Enable);
2016-01-27 09:11:59 +00:00
2022-10-10 00:22:17 +00:00
void * GetDebugMenu(void)
{
return m_RSPDebug.hRSPMenu;
}
2016-01-27 09:11:59 +00:00
void ProcessMenuItem(int32_t id);
private:
2022-10-10 00:22:17 +00:00
CRSP_Plugin(const CRSP_Plugin &);
CRSP_Plugin & operator=(const CRSP_Plugin &);
2016-01-27 09:11:59 +00:00
2022-10-10 00:22:17 +00:00
PLUGIN_TYPE type()
{
return PLUGIN_TYPE_RSP;
}
virtual int32_t GetDefaultSettingStartRange() const
{
return FirstRSPDefaultSet;
}
virtual int32_t GetSettingStartRange() const
{
return FirstRSPSettings;
}
2016-01-27 09:11:59 +00:00
bool LoadFunctions(void);
void UnloadPluginDetails(void);
RSPDEBUG_INFO m_RSPDebug;
2022-10-10 00:22:17 +00:00
uint32_t m_CycleCount;
2016-01-27 09:11:59 +00:00
2022-10-10 00:22:17 +00:00
void(CALL * GetDebugInfo)(RSPDEBUG_INFO * GFXDebugInfo);
void(CALL * InitiateDebugger)(DEBUG_INFO DebugInfo);
2016-01-27 09:11:59 +00:00
};