mirror of https://github.com/PCSX2/pcsx2.git
Added GameFix for Transformers and Test Drive Unlimited to solve the slow booting issue, Test Drive is now playable at least :P. Also tidied up a small bit of VIF DIRECT/HL, no functional changes made.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4608 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
157c6ef432
commit
e615fe1c08
|
@ -52,6 +52,7 @@ enum GamefixId
|
|||
Fix_SkipMpeg,
|
||||
Fix_OPHFlag,
|
||||
Fix_DMABusy,
|
||||
Fix_VIFFIFO,
|
||||
|
||||
GamefixId_COUNT
|
||||
};
|
||||
|
@ -341,7 +342,8 @@ struct Pcsx2Config
|
|||
EETimingHack :1, // General purpose timing hack.
|
||||
SkipMPEGHack :1, // Skips MPEG videos (Katamari and other games need this)
|
||||
OPHFlagHack :1, // Bleach Blade Battlers
|
||||
DMABusyHack :1; // Denies writes to the DMAC when it's busy. This is correct behaviour but bad timing can cause problems.
|
||||
DMABusyHack :1, // Denies writes to the DMAC when it's busy. This is correct behaviour but bad timing can cause problems.
|
||||
VIFFIFOHack :1; // Pretends to fill the non-existant VIF FIFO Buffer.
|
||||
BITFIELD_END
|
||||
|
||||
GamefixOptions();
|
||||
|
@ -487,6 +489,7 @@ TraceLogFilters& SetTraceConfig();
|
|||
#define CHECK_SKIPMPEGHACK (EmuConfig.Gamefixes.SkipMPEGHack) // Finds sceMpegIsEnd pattern to tell the game the mpeg is finished (Katamari and a lot of games need this)
|
||||
#define CHECK_OPHFLAGHACK (EmuConfig.Gamefixes.OPHFlagHack) // Bleach Blade Battlers
|
||||
#define CHECK_DMABUSYHACK (EmuConfig.Gamefixes.DMABusyHack) // Denies writes to the DMAC when it's busy. This is correct behaviour but bad timing can cause problems.
|
||||
#define CHECK_VIFFIFOHACK (EmuConfig.Gamefixes.VIFFIFOHack) // Pretends to fill the non-existant VIF FIFO Buffer.
|
||||
|
||||
//------------ Advanced Options!!! ---------------
|
||||
#define CHECK_VU_OVERFLOW (EmuConfig.Cpu.Recompiler.vuOverflow)
|
||||
|
|
|
@ -136,6 +136,11 @@ mem32_t __fastcall _hwRead32(u32 mem)
|
|||
}
|
||||
break;
|
||||
}
|
||||
//Hack for Transformers and Test Drive Unlimited to simulate filling the VIF FIFO
|
||||
//It actually stalls VIF a few QW before the end of the transfer, so we need to pretend its all gone
|
||||
//else itll take aaaaaaaaages to boot.
|
||||
if(mem == (D1_CHCR + 0x10) && CHECK_VIFFIFOHACK)
|
||||
return psHu32(mem) + (vif1ch.qwc * 16);
|
||||
|
||||
return psHu32(mem);
|
||||
}
|
||||
|
|
|
@ -252,7 +252,8 @@ const wxChar *const tbl_GamefixNames[] =
|
|||
L"EETiming",
|
||||
L"SkipMpeg",
|
||||
L"OPHFlag",
|
||||
L"DMABusy"
|
||||
L"DMABusy",
|
||||
L"VIFFIFO"
|
||||
};
|
||||
|
||||
const __fi wxChar* EnumToString( GamefixId id )
|
||||
|
@ -310,6 +311,7 @@ void Pcsx2Config::GamefixOptions::Set( GamefixId id, bool enabled )
|
|||
case Fix_SkipMpeg: SkipMPEGHack = enabled; break;
|
||||
case Fix_OPHFlag: OPHFlagHack = enabled; break;
|
||||
case Fix_DMABusy: DMABusyHack = enabled; break;
|
||||
case Fix_VIFFIFO: VIFFIFOHack = enabled; break;
|
||||
|
||||
jNO_DEFAULT;
|
||||
}
|
||||
|
@ -331,8 +333,9 @@ bool Pcsx2Config::GamefixOptions::Get( GamefixId id ) const
|
|||
case Fix_SkipMpeg: return SkipMPEGHack;
|
||||
case Fix_OPHFlag: return OPHFlagHack;
|
||||
case Fix_DMABusy: return DMABusyHack;
|
||||
case Fix_VIFFIFO: return VIFFIFOHack;
|
||||
|
||||
jNO_DEFAULT
|
||||
jNO_DEFAULT;
|
||||
}
|
||||
return false; // unreachable, but we still need to suppress warnings >_<
|
||||
}
|
||||
|
@ -352,6 +355,7 @@ void Pcsx2Config::GamefixOptions::LoadSave( IniInterface& ini )
|
|||
IniBitBool( SkipMPEGHack );
|
||||
IniBitBool( OPHFlagHack );
|
||||
IniBitBool( DMABusyHack );
|
||||
IniBitBool( VIFFIFOHack );
|
||||
}
|
||||
|
||||
Pcsx2Config::Pcsx2Config()
|
||||
|
|
|
@ -200,15 +200,12 @@ template<int idx> __fi int _vifCode_Direct(int pass, const u8* data, bool isDire
|
|||
// only seems to happen on TTE mode transfers with their split-64-bit packets, there shouldn't
|
||||
// be any need to worry about queuing more than 16 bytes of data,
|
||||
//
|
||||
|
||||
|
||||
|
||||
ret = 0;
|
||||
minSize = aMin(minSize, 4-partial_count);
|
||||
|
||||
for( uint i=0; i<(minSize & 3); ++i)
|
||||
{
|
||||
partial_write[partial_count++] = ((u32*)data)[i];
|
||||
ret++;
|
||||
|
||||
}
|
||||
|
||||
pxAssume( partial_count <= 4 );
|
||||
|
@ -220,6 +217,8 @@ template<int idx> __fi int _vifCode_Direct(int pass, const u8* data, bool isDire
|
|||
GetMTGS().SendDataPacket();
|
||||
partial_count = 0;
|
||||
}
|
||||
|
||||
ret = minSize;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -242,7 +241,9 @@ template<int idx> __fi int _vifCode_Direct(int pass, const u8* data, bool isDire
|
|||
{
|
||||
vif1.cmd = 0;
|
||||
}
|
||||
|
||||
vif1.vifstalled = true;
|
||||
|
||||
return ret;
|
||||
}
|
||||
return 0;
|
||||
|
|
|
@ -90,6 +90,14 @@ Panels::GameFixesPanel::GameFixesPanel( wxWindow* parent )
|
|||
L"Known to affect following games:\n"
|
||||
L" * Mana Khemia 1 (Going \"off campus\")\n"
|
||||
)
|
||||
},
|
||||
{
|
||||
_("Simulate VIF1 FIFO read ahead. Fixes slow loading games."),
|
||||
pxEt( "!ContextTip:Gamefixes:VIF1 FIFO hack",
|
||||
L"Known to affect following games:\n"
|
||||
L" * Test Drive Unlimited\n"
|
||||
L" * Transformers"
|
||||
)
|
||||
}
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue