1
0
mirror of https://github.com/RPCS3/rpcs3.git synced 2024-11-25 04:02:42 +01:00

Test alterable aggregates via overriding be_t

Checking how it might look like without introducing too many changes.
Alteration of its behaviour as a "template template" argument allows:
 - normal access
 - easier aggregate inspection
 - memory access interception
This commit is contained in:
Nekotekina 2021-04-25 18:55:29 +03:00
parent b5e9f09972
commit 86a8e0716f
2 changed files with 7 additions and 3 deletions

View File

@ -1065,6 +1065,8 @@ DECLARE(ppu_module_manager::cellSail)("cellSail", []()
{
static ppu_static_module cellSailAvi("cellSailAvi");
[[maybe_unused]] vm::ptr<CellSailMp4MovieInfo<>> test;
REG_FUNC(cellSail, cellSailMemAllocatorInitialize);
REG_FUNC(cellSail, cellSailFutureInitialize);

View File

@ -933,9 +933,10 @@ struct CellSailSourceCheckResource
CellSailSourceCheckStream runningError;
};
template <template <class T, usz A = alignof(T)> class be_t = ::be_t>
struct CellSailMp4DateTime
{
be_t<u16> second;
be_t<u16, 2> second;
be_t<u16> minute;
be_t<u16> hour;
be_t<u16> day;
@ -950,10 +951,11 @@ struct CellSailMp4Movie
be_t<u64> internalData[16];
};
template <template <class T, usz A = alignof(T)> class be_t = ::be_t>
struct CellSailMp4MovieInfo
{
CellSailMp4DateTime creationDateTime;
CellSailMp4DateTime modificationDateTime;
CellSailMp4DateTime<be_t> creationDateTime;
CellSailMp4DateTime<be_t> modificationDateTime;
be_t<u32> trackCount;
be_t<u32> movieTimeScale;
be_t<u32> movieDuration;