mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-29 20:28:56 +00:00
TMEM: Handle savestate and init
This commit is contained in:
parent
88bd10cd30
commit
a33cf27885
5 changed files with 27 additions and 4 deletions
|
@ -4,6 +4,8 @@
|
|||
|
||||
#include <array>
|
||||
|
||||
#include "Common/ChunkFile.h"
|
||||
|
||||
#include "VideoCommon/BPMemory.h"
|
||||
#include "VideoCommon/TMEM.h"
|
||||
|
||||
|
@ -32,9 +34,9 @@ struct TextureUnitState
|
|||
bool Overlaps(const BankConfig& other) const;
|
||||
};
|
||||
|
||||
BankConfig even;
|
||||
BankConfig odd;
|
||||
State state;
|
||||
BankConfig even = {};
|
||||
BankConfig odd = {};
|
||||
State state = State::INVALID;
|
||||
|
||||
bool Overlaps(const TextureUnitState& other) const;
|
||||
};
|
||||
|
@ -221,4 +223,14 @@ bool IsValid(u32 unit)
|
|||
return s_unit[unit].state != TextureUnitState::State::INVALID;
|
||||
}
|
||||
|
||||
void Init()
|
||||
{
|
||||
s_unit.fill({});
|
||||
}
|
||||
|
||||
void DoState(PointerWrap& p)
|
||||
{
|
||||
p.DoArray(s_unit);
|
||||
}
|
||||
|
||||
} // namespace TMEM
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue