mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-22 13:49:53 -06:00
Mechanical changes to move most CP state to a struct rather than separate globals.
The next commit will add a separate copy of the struct and the ability for LoadCPReg to work on it.
This commit is contained in:
@ -231,12 +231,6 @@ union TMatrixIndexB
|
||||
|
||||
#pragma pack()
|
||||
|
||||
extern u32 arraybases[16];
|
||||
extern u8 *cached_arraybases[16];
|
||||
extern u32 arraystrides[16];
|
||||
extern TMatrixIndexA MatrixIndexA;
|
||||
extern TMatrixIndexB MatrixIndexB;
|
||||
|
||||
struct VAT
|
||||
{
|
||||
UVAT_group0 g0;
|
||||
@ -244,8 +238,25 @@ struct VAT
|
||||
UVAT_group2 g2;
|
||||
};
|
||||
|
||||
extern TVtxDesc g_VtxDesc;
|
||||
extern VAT g_VtxAttr[8];
|
||||
// STATE_TO_SAVE
|
||||
struct CPState final
|
||||
{
|
||||
u32 array_bases[16];
|
||||
u32 array_strides[16];
|
||||
TMatrixIndexA matrix_index_a;
|
||||
TMatrixIndexB matrix_index_b;
|
||||
TVtxDesc vtx_desc;
|
||||
// Most games only use the first VtxAttr and simply reconfigure it all the time as needed.
|
||||
VAT vtx_attr[8];
|
||||
};
|
||||
|
||||
class PointerWrap;
|
||||
|
||||
extern void DoCPState(PointerWrap& p);
|
||||
|
||||
extern CPState g_main_cp_state;
|
||||
|
||||
extern u8 *cached_arraybases[16];
|
||||
|
||||
// Might move this into its own file later.
|
||||
void LoadCPReg(u32 SubCmd, u32 Value);
|
||||
|
Reference in New Issue
Block a user