GSdx: CRC hackfixes!

Summary of changes...

Fixed menus and HUD for Spyro: A New Beginning and Spyro: the Eternal Night.

Fixed missing dialogs and reduced the VRam usage a bit for Tales of Legendia ("8-bit textures" help a bit more with Vram/speed). Should be playable now in hardware mode. Thanks to rama for figuring it could be hackfixed this way and the initial patch :)

Half-screen fixes for Ty the Tasmanian Tiger 2, X-men Origins: Wolverine, Call of Duty: World at War - Final Fronts.

Modified the Star Wars: Force Unleashed hackfix a bit, shouldn't have the see-thru objects anymore.
Also modified the Metal Gear Solid 3 and Gran Turismo 4 hackfixes as they needed different skip values for each region (PAL/NTSC). Thanx to avih for the region code... and the free C/C++ lessons :P

The hackfix for Sly 3 was still showing stripes for 3-D and two-player modes, fixed for NTSC version now and hopefully works for PAL one too.

Couple GameDB updates after the gif rewrite.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4833 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
shadowladyngemu 2011-07-29 18:11:22 +00:00
parent a4059b45b5
commit 52a0eb047d
5 changed files with 273 additions and 71 deletions

View File

@ -3656,7 +3656,7 @@ Region = NTSC-U
Serial = SLUS-20467
Name = Tomb Raider - The Angel of Darkness
Region = NTSC-U
Compat = 4
Compat = 2
---------------------------------------------
Serial = SLUS-20468
Name = Dynasty Tactics
@ -4097,7 +4097,7 @@ Compat = 2
Serial = SLUS-20566
Name = Buffy the Vampire Slayer - Chaos Bleeds
Region = NTSC-U
Compat = 5
Compat = 4
EETimingHack = 1 //garbage in HUD
---------------------------------------------
Serial = SLUS-20567
@ -4180,7 +4180,6 @@ Serial = SLUS-20585
Name = Powerpuff Girls, The - Relish Rampage
Region = NTSC-U
Compat = 5
EETimingHack = 1 //hang showing "Press start"
---------------------------------------------
Serial = SLUS-20586
Name = IHRA Drag Racing 2
@ -4271,7 +4270,8 @@ Compat = 5
Serial = SLUS-20607
Name = Disney's Extreme Skate Adventure
Region = NTSC-U
Compat = 2
Compat = 5
vuRoundMode = 0
---------------------------------------------
Serial = SLUS-20608
Name = Mobile Light Force 2
@ -4656,7 +4656,6 @@ Serial = SLUS-20694
Name = Onimusha 3 - Demon Siege
Region = NTSC-U
Compat = 5
EETimingHack = 1 //sliced FMVs
---------------------------------------------
Serial = SLUS-20695
Name = Chaos Legion
@ -4820,7 +4819,6 @@ Name = Drakengard
Region = NTSC-U
Compat = 5
eeClampMode = 3 //characters are visible in-game.
EETimingHack = 1 //flickering textures.
---------------------------------------------
Serial = SLUS-20733
Name = Castlevania - Lament of Innocence
@ -5173,6 +5171,7 @@ Serial = SLUS-20811
Name = Need for Speed - Underground
Region = NTSC-U
Compat = 5
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLUS-20812
Name = Dynasty Warriors 4 - Extreme Edition
@ -5338,7 +5337,7 @@ SkipMPEGHack = 1 //hangs on menus
Serial = SLUS-20852
Name = Terminator 3, The - The Redemption
Region = NTSC-U
Compat = 2
Compat = 4
---------------------------------------------
Serial = SLUS-20853
Name = Looney Tunes - Back in Action
@ -5574,7 +5573,6 @@ Serial = SLUS-20901
Name = FlatOut
Region = NTSC-U
Compat = 5
EETimingHack = 1 //random hang
---------------------------------------------
Serial = SLUS-20902
Name = Shadow of Rome
@ -5871,8 +5869,8 @@ Compat = 4
comment=Patches By Nachbrenner
//fix IPU busy! ingame
patch=0,EE,003a9538,word,03e00008
patch=0,EE,003a953c,word,00000000
//patch=0,EE,003a9538,word,03e00008
//patch=0,EE,003a953c,word,00000000
patch=0,EE,003a9460,word,03e00008
patch=0,EE,003a9464,word,00000000
@ -6730,6 +6728,7 @@ Serial = SLUS-21145
Name = Full Spectrum Warrior
Region = NTSC-U
Compat = 5
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLUS-21146
Name = Far East of Eden
@ -7228,6 +7227,7 @@ Serial = SLUS-21250
Name = Full Spectrum Warrior - Ten Hammers
Region = NTSC-U
Compat = 5
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLUS-21251
Name = FlatOut 2
@ -7819,13 +7819,12 @@ Region = NTSC-U
Serial = SLUS-21372
Name = Legend of Spyro, The - A New Beginning
Region = NTSC-U
Compat = 4
Compat = 5
---------------------------------------------
Serial = SLUS-21373
Name = Drakengard 2
Region = NTSC-U
Compat = 5
EETimingHack = 1 //flickering textures.
---------------------------------------------
Serial = SLUS-21374
Name = Marvel - Ultimate Alliance
@ -8775,7 +8774,7 @@ Compat = 5
Serial = SLUS-21607
Name = Legend of Spyro, The - The Eternal Night
Region = NTSC-U
Compat = 4
Compat = 5
---------------------------------------------
Serial = SLUS-21608
Name = Dance Dance Revolution - SuperNOVA 2
@ -8977,7 +8976,8 @@ Region = NTSC-U
Serial = SLUS-21650
Name = Mercenaries 2 - World in Flames
Region = NTSC-U
Compat = 2
Compat = 4
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLUS-21651
Name = Noddy and the Magic Book
@ -9041,6 +9041,7 @@ Serial = SLUS-21665
Name = Simpsons Game, The
Region = NTSC-U
Compat = 5
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLUS-21666
Name = Mountain Bike Adrenaline
@ -10072,7 +10073,6 @@ Serial = SLUS-21915
Name = The Lord of the Rings: Aragorn's Quest
Region = NTSC-U
Compat = 5
EETimingHack = 1 //SPS
---------------------------------------------
Serial = SLUS-21917
Name = Dance Dance Revolution X2 (Bundle)
@ -10566,6 +10566,7 @@ Region = NTSC-U
Serial = SLUS-29073
Name = Need for Speed - Underground [Demo]
Region = NTSC-U
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLUS-29074
Name = Dance Dance Revolution Max 2 [Demo]
@ -13770,7 +13771,7 @@ Region = NTSC-K
Serial = SLKA-25320
Name = Ikusa Gami
Region = NTSC-K
Compat = 4
Compat = 5
---------------------------------------------
Serial = SLKA-25321
Name = K.League - Winning Eleven 9 - Asia Championship
@ -18513,6 +18514,7 @@ Region = NTSC-J
Serial = SLPM-65614
Name = Need for Speed Underground [EA Best Hits]
Region = NTSC-J
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLPM-65615
Name = Dokapon DX
@ -20846,6 +20848,7 @@ Region = NTSC-J
Serial = SLPM-66263
Name = Full Spectrum Warrior
Region = NTSC-J
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLPM-66264
Name = Canvas 2 - Niji-iro no Sketch [Deluxe Pack]
@ -21393,6 +21396,7 @@ Region = NTSC-J
Serial = SLPM-66427
Name = Full Spectrum Warrior - Ten Hammers
Region = NTSC-J
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLPM-66429
Name = Special Forces - Fire for Effect
@ -33122,7 +33126,7 @@ Compat = 5
Serial = SLES-51227
Name = Tomb Raider - Angel of Darkness
Region = PAL-Unk
Compat = 4
Compat = 2
---------------------------------------------
Serial = SLES-51229
Name = Virtua Cop - Elite Edition
@ -34058,6 +34062,7 @@ Compat = 5
Serial = SLES-51720
Name = Disney's Extreme Skate Adventure
Region = PAL-Unk
vuRoundMode = 0
---------------------------------------------
Serial = SLES-51723
Name = Hobbit, The
@ -34630,6 +34635,7 @@ Serial = SLES-51967
Name = Need for Speed - Underground
Region = PAL-M4
Compat = 5
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLES-51968
Name = Spongebob Squarepants - Battle for Bikini Bottom
@ -35247,7 +35253,6 @@ Name = Drakengard
Region = PAL-Unk
Compat = 5
eeClampMode = 3 //characters are visible in-game.
EETimingHack = 1 //flickering textures.
---------------------------------------------
Serial = SLES-52323
Name = Richard Burns Rally
@ -37119,6 +37124,7 @@ Region = PAL-Unk
Serial = SLES-53114
Name = Full Spectrum Warrior
Region = PAL-Unk
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-53119
Name = Kessen III
@ -37156,6 +37162,7 @@ Region = PAL-Unk
Serial = SLES-53131
Name = Full Spectrum Warrior
Region = PAL-R
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-53138
Name = Outlaw Volleyball - Remixed
@ -38169,6 +38176,7 @@ Compat = 4
Serial = SLES-53656
Name = Full Spectrum Warrior - Ten Hammers
Region = PAL-Unk
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-53657
Name = Shrek - Super Slam
@ -38470,7 +38478,6 @@ Region = PAL-E
Serial = SLES-53794
Name = Drakengard 2
Region = PAL-Unk
EETimingHack = 1 //flickering textures.
---------------------------------------------
Serial = SLES-53796
Name = FIFA Street 2
@ -38690,6 +38697,7 @@ Compat = 5
Serial = SLES-53909
Name = Full Spectrum Warrior - Ten Hammers
Region = PAL-Unk
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-53910
Name = Agent Hugo
@ -38870,7 +38878,6 @@ Serial = SLES-54002
Name = FlatOut 2
Region = PAL-M5
Compat = 5
EETimingHack = 1 //random hang
---------------------------------------------
Serial = SLES-54003
Name = Flatout 2
@ -39060,6 +39067,7 @@ Serial = SLES-54115
Name = Delta Force - Black Hawk Down - Team Sabre
Region = PAL-Unk
Compat = 5
EETimingHack = 1 //missing text
---------------------------------------------
Serial = SLES-54116
Name = Operation Winback 2 - Project Poseidon
@ -40298,8 +40306,7 @@ Region = PAL-E
Serial = SLES-54815
Name = Spyro - The Eternal Night
Region = PAL-M6
Compat = 4
SkipMPEGHack = 1
Compat = 5
---------------------------------------------
Serial = SLES-54819
Name = Manhunt 2
@ -40434,10 +40441,12 @@ Serial = SLES-54904
Name = The Simpsons Game
Region = PAL-M4
Compat = 5
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLES-54906
Name = The Simpsons Game
Region = PAL-I-S
EETimingHack = 1 //broken textures
---------------------------------------------
Serial = SLES-54913
Name = Pro Evolution Soccer 2008
@ -40554,6 +40563,7 @@ Serial = SLES-54997
Name = Mercenaries 2 - World in Flames
Region = PAL-Unk
Compat = 5
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-54998
Name = Bratz - The Movie
@ -40562,10 +40572,12 @@ Region = PAL-M5
Serial = SLES-55000
Name = Mercenaries 2 - World in Flames
Region = PAL-G
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-55001
Name = Mercenaries 2 - World in Flames
Region = PAL-S
EETimingHack = 1 //flickery textures
---------------------------------------------
Serial = SLES-55002
Name = Need for Speed - ProStreet
@ -40714,7 +40726,7 @@ Region = PAL-Unk
Compat = 5
---------------------------------------------
Serial = SLES-55163
Name = the Legend of Spyro - Dawn of the Dragon
Name = The Legend of Spyro - Dawn of the Dragon
Region = PAL-M6
---------------------------------------------
Serial = SLES-55169

View File

@ -33,30 +33,30 @@ CRC::Game CRC::m_games[] =
{0xC8EE2562, PiaCarroteYoukosoGPGakuenPrincess, JP, PointListPalette},
{0x6CF94A43, KazokuKeikakuKokoroNoKizuna, JP, PointListPalette},
{0xEDAF602D, DuelSaviorDestiny, JP, PointListPalette},
{0xa39517ab, FFX, EU, 0},
{0xa39517ae, FFX, FR, 0},
{0x941bb7d9, FFX, DE, 0},
{0xa39517a9, FFX, IT, 0},
{0x941bb7de, FFX, ES, 0},
{0xb4414ea1, FFX, RU, 0},
{0xee97db5b, FFX, RU, 0},
{0xaec495cc, FFX, RU, 0},
{0xbb3d833a, FFX, US, 0},
{0x6a4efe60, FFX, JP, 0},
{0x3866ca7e, FFX, ASIA, 0}, // int.
{0x658597e2, FFX, JP, 0}, // int.
{0x9aac5309, FFX2, EU, 0},
{0x9aac530c, FFX2, FR, 0},
{0x9aac530a, FFX2, FR, 0}, // ?
{0x9aac530d, FFX2, DE, 0},
{0x9aac530b, FFX2, IT, 0},
{0x48fe0c71, FFX2, US, 0},
{0xA39517AB, FFX, EU, 0},
{0xA39517AE, FFX, FR, 0},
{0x941BB7D9, FFX, DE, 0},
{0xA39517A9, FFX, IT, 0},
{0x941BB7DE, FFX, ES, 0},
{0xB4414EA1, FFX, RU, 0},
{0xEE97DB5B, FFX, RU, 0},
{0xAEC495CC, FFX, RU, 0},
{0xBB3D833A, FFX, US, 0},
{0x6A4EFE60, FFX, JP, 0},
{0x3866CA7E, FFX, ASIA, 0}, // int.
{0x658597E2, FFX, JP, 0}, // int.
{0x9AAC5309, FFX2, EU, 0},
{0x9AAC530C, FFX2, FR, 0},
{0x9AAC530A, FFX2, FR, 0}, // ?
{0x9AAC530D, FFX2, DE, 0},
{0x9AAC530B, FFX2, IT, 0},
{0x48FE0C71, FFX2, US, 0},
{0x8A6D7F14, FFX2, JP, 0},
{0xe1fd9a2d, FFX2, JP, 0}, // int.
{0x78da0252, FFXII, EU, 0},
{0xc1274668, FFXII, EU, 0},
{0xdc2a467e, FFXII, EU, 0},
{0xca284668, FFXII, EU, 0},
{0xE1FD9A2D, FFX2, JP, 0}, // int.
{0x78DA0252, FFXII, EU, 0},
{0xC1274668, FFXII, EU, 0},
{0xDC2A467E, FFXII, EU, 0},
{0xCA284668, FFXII, EU, 0},
{0x280AD120, FFXII, JP, 0},
{0x08C1ED4D, HauntingGround, NoRegion, 0},
{0x2CD5794C, HauntingGround, EU, 0},
@ -68,19 +68,19 @@ CRC::Game CRC::m_games[] =
{0xDEFA4763, ShadowHearts, US, 0},
{0xDDFB18B0, ShadowHearts, JP, 0},
{0x21068223, Okami, US, 0},
{0x891f223f, Okami, FR, 0},
{0x891F223F, Okami, FR, 0},
{0xC5DEFEA0, Okami, JP, 0},
{0x053D2239, MetalGearSolid3, US, 0},
{0x086273D2, MetalGearSolid3, FR, 0},
{0x26A6E286, MetalGearSolid3, EU, 0},
{0xAA31B5BF, MetalGearSolid3, NoRegion, 0},
{0x9F185CE1, MetalGearSolid3, NoRegion, 0},
{0x9F185CE1, MetalGearSolid3, EU, 0},
{0x98D4BC93, MetalGearSolid3, EU, 0},
{0x86BC3040, MetalGearSolid3, US, 0}, //Subsistance disc 1
{0x0481AD8A, MetalGearSolid3, JP, 0},
{0x79ED26AD, MetalGearSolid3, EU, 0},
{0x5E31EA42, MetalGearSolid3, EU, 0},
{0xD7ED797D, MetalGearSolid3, EU, 0},
{0x053D2239, MetalGearSolid3, US, 0},
{0xAA31B5BF, MetalGearSolid3, US, 0},
{0x86BC3040, MetalGearSolid3, US, 0}, //Subsistance disc 1
{0x0481AD8A, MetalGearSolid3, JP, 0},
{0x278722BF, DBZBT2, US, 0},
{0xFE961D28, DBZBT2, US, 0},
{0x0393B6BE, DBZBT2, EU, 0},
@ -109,9 +109,10 @@ CRC::Game CRC::m_games[] =
{0x7ACF7E03, ICO, NoRegion, 0},
{0xAEAD1CA3, GT4, JP, 0},
{0x30E41D93, GT4, KO, 0},
{0x44A61C8F, GT4, NoRegion, 0},
{0x0086E35B, GT4, NoRegion, 0},
{0x77E61C8A, GT4, NoRegion, 0},
{0x44A61C8F, GT4, EU, 0},
{0x0086E35B, GT4, EU, 0},
{0x77E61C8A, GT4, US, 0},
{0x33C6E35E, GT4, US, 0},
{0x85AE91B3, GT3, US, 0},
{0xC220951A, GT3, NoRegion, 0},
{0x60013EBD, GTConcept, EU, 0},
@ -135,6 +136,7 @@ CRC::Game CRC::m_games[] =
{0x5F254B7C, ResidentEvil4, KO, 0},
{0x72E1E60E, Spartan, NoRegion, 0},
{0x26689C87, Spartan, JP, 0},
{0xA32F7CD0, AceCombat4, US, 0},
{0x5ED8FB53, AceCombat4, JP, 0},
{0x1B9B7563, AceCombat4, NoRegion, 0},
{0xEC432B24, Drakengard2, EU, 0},
@ -161,11 +163,11 @@ CRC::Game CRC::m_games[] =
{0xE96E55BD, GodOfWar2, JP, 0},
{0xF8CD3DF6, GodOfWar2, NoRegion, 0},
{0x0B82BFF7, GodOfWar2, NoRegion, 0},
{0x5990866f, GodOfWar2, NoRegion, 0},
{0x5990866F, GodOfWar2, NoRegion, 0},
{0xDCD9A9F7, GodOfWar2, NoRegion, 0},
{0x5D482F18, JackieChanAdv, NoRegion, 0},
{0xf0a6d880, HarvestMoon, US, 0},
{0x75c01a04, NamcoXCapcom, US, 0},
{0xF0A6D880, HarvestMoon, US, 0},
{0x75C01A04, NamcoXCapcom, US, 0},
{0xBF6F101F, GiTS, US, 0},
{0x95CC86EF, GiTS, US, 0},
{0xA5768F53, GiTS, JP, 0},
@ -268,11 +270,13 @@ CRC::Game CRC::m_games[] =
{0xB3A9F9ED, Black, JP, 0},
{0x4F755D39, TyTasmanianTiger, US, 0},
{0xD59D3252, TyTasmanianTiger, EU, 0},
{0x5A1BB2A1, TyTasmanianTiger2, US, 0},
{0x44A5FA15, FFVIIDoC, US, 0},
{0x33F7D21A, FFVIIDoC, EU, 0},
{0xAFAC88EF, FFVIIDoC, JP, 0},
{0x568A5C78, DigimonRumbleArena2, US, 0},
{0x785E22BB, DigimonRumbleArena2, EU, 0},
{0x4C5CE4C3, DigimonRumbleArena2, EU, 0},
{0x879CDA5E, StarWarsForceUnleashed, US, 0},
{0x503BF9E1, StarWarsBattlefront, NoRegion, 0}, //EU and US versions have same CRC
{0x02F4B541, StarWarsBattlefront2, NoRegion, 0}, //EU and US versions have same CRC
@ -292,6 +296,14 @@ CRC::Game CRC::m_games[] =
{0x4A0E5B3A, MidnightClub3, US, 0}, //dub
{0xEBE1972D, MidnightClub3, EU, 0}, //dub
{0x60A42FF5, MidnightClub3, US, 0}, //remix
{0x4B1A0FFA, XmenOriginsWolverine, US, 0},
{0xBFF3DBCB, CallofDutyFinalFronts, US, 0},
{0xD03D4C77, SpyroNewBeginning, US, 0},
{0x0EE5646B, SpyroNewBeginning, EU, 0},
{0xB80CE8EC, SpyroEternalNight, US, 0},
{0x8AE9536D, SpyroEternalNight, EU, 0},
{0x43AB7214, TalesOfLegendia, US, 0},
{0x1F8640E0, TalesOfLegendia, JP, 0},
};
hash_map<uint32, CRC::Game*> CRC::m_map;

View File

@ -104,6 +104,7 @@ public:
CastlevaniaLoI,
Black,
TyTasmanianTiger,
TyTasmanianTiger2,
FFVIIDoC,
DigimonRumbleArena2,
StarWarsForceUnleashed,
@ -115,6 +116,11 @@ public:
BurnoutRevenge,
BurnoutDominator,
MidnightClub3,
XmenOriginsWolverine,
CallofDutyFinalFronts,
SpyroNewBeginning,
SpyroEternalNight,
TalesOfLegendia,
TitleCount,
};

View File

@ -264,7 +264,7 @@ class GSRendererHW : public GSRendererT<Vertex>
uint32 FBP = m_context->FRAME.Block();
uint32 FBW = m_context->FRAME.FBW;
uint32 FPSM = m_context->FRAME.PSM;
if((FBP == 0x02800 || FBP == 0x02BC0) && FPSM == PSM_PSMCT24) //0x2800 pal, 0x2bc0 ntsc
{
//half height buffer clear
@ -272,7 +272,7 @@ class GSRendererHW : public GSRendererT<Vertex>
return false;
}
return true;
}
@ -314,21 +314,125 @@ class GSRendererHW : public GSRendererT<Vertex>
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
if(FPSM == PSM_PSMCT24 && FBP == 0x2bc0)
if(!PRIM->TME)
{
m_dev->ClearDepth(ds, 0);
if(FPSM == PSM_PSMCT24 && FBP == 0x2bc0)
{
m_dev->ClearDepth(ds, 0);
return false;
return false;
}
}
else if((FBP == 0x36e0 || FBP == 0x34a0) && FPSM == PSM_PSMCT24)
else if(PRIM->TME)
{
if((FBP == 0x0 || FBP == 0x01180) && FPSM == PSM_PSMCT32 && (m_vt.m_max.p.z == m_vt.m_min.p.z && m_vt.m_max.p.z == 0))
{
m_dev->ClearDepth(ds, 0);
}
}
return true;
}
bool OI_XmenOriginsWolverine(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
if(FBP == 0x0 && FPSM == PSM_PSMCT16)
{
//half height buffer clear
m_dev->ClearDepth(ds, 0);
}
return true;
}
bool OI_CallofDutyFinalFronts(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
if(FBP == 0x02300 && FPSM == PSM_PSMZ24)
{
//half height buffer clear
m_dev->ClearDepth(ds, 0);
return false;
}
return true;
}
bool OI_SpyroNewBeginning(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
uint32 ZTE = m_context->TEST.ZTE;
if(!PRIM->TME)
{
if(FPSM == PSM_PSMCT24 && (FBP == 0x02800 || FBP == 0x02bc0)) //0x2800 pal, 0x2bc0 ntsc
{
//half height buffer clear
m_dev->ClearDepth(ds, 0);
return false;
}
}
else if(PRIM->TME)
{
if(ZTE && (FBP == 0x0 || FBP == 0x01180) && FPSM == PSM_PSMCT32 && (m_vt.m_max.p.z == m_vt.m_min.p.z && m_vt.m_min.p.z == 0x0))
{
m_dev->ClearDepth(ds, 0);
}
}
return true;
}
bool OI_SpyroEternalNight(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
uint32 ZTE = m_context->TEST.ZTE;
if(!PRIM->TME)
{
if(FPSM == PSM_PSMCT24 && FBP == 0x2bc0)
{
//half height buffer clear
m_dev->ClearDepth(ds, 0);
return false;
}
}
else if(PRIM->TME)
{
if(ZTE && (FBP == 0x0 || FBP == 0x01180) && FPSM == PSM_PSMCT32 && (m_vt.m_max.p.z == m_vt.m_min.p.z && m_vt.m_min.p.z == 0x0))
{
m_dev->ClearDepth(ds, 0);
}
}
return true;
}
bool OI_TalesOfLegendia(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
uint32 FBP = m_context->FRAME.Block();
uint32 FPSM = m_context->FRAME.PSM;
if (FPSM == PSM_PSMCT32 && FBP == 0x01c00 && !m_context->TEST.ATE && m_vt.m_max.p.z == m_vt.m_min.p.z)
{
m_context->TEST.ZTST = ZTST_ALWAYS;
//m_dev->ClearDepth(ds, 0);
}
return true;
}
bool OI_PointListPalette(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
{
if(m_vt.m_primclass == GS_POINT_CLASS && !PRIM->TME)
@ -511,10 +615,16 @@ class GSRendererHW : public GSRendererT<Vertex>
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::RozenMaidenGebetGarden, CRC::RegionCount, &GSRendererHW::OI_RozenMaidenGebetGarden));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::SpidermanWoS, CRC::RegionCount, &GSRendererHW::OI_SpidermanWoS));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::TyTasmanianTiger, CRC::RegionCount, &GSRendererHW::OI_TyTasmanianTiger));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::TyTasmanianTiger2, CRC::RegionCount, &GSRendererHW::OI_TyTasmanianTiger));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::DigimonRumbleArena2, CRC::RegionCount, &GSRendererHW::OI_DigimonRumbleArena2));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::StarWarsForceUnleashed, CRC::RegionCount, &GSRendererHW::OI_StarWarsForceUnleashed));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::BlackHawkDown, CRC::RegionCount, &GSRendererHW::OI_BlackHawkDown));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::XmenOriginsWolverine, CRC::RegionCount, &GSRendererHW::OI_XmenOriginsWolverine));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::CallofDutyFinalFronts, CRC::RegionCount, &GSRendererHW::OI_CallofDutyFinalFronts));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::SpyroNewBeginning, CRC::RegionCount, &GSRendererHW::OI_SpyroNewBeginning));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::SpyroEternalNight, CRC::RegionCount, &GSRendererHW::OI_SpyroEternalNight));
m_oi_list.push_back(HackEntry<OI_Ptr>(CRC::TalesOfLegendia, CRC::RegionCount, &GSRendererHW::OI_TalesOfLegendia));
m_oo_list.push_back(HackEntry<OO_Ptr>(CRC::DBZBT2, CRC::RegionCount, &GSRendererHW::OO_DBZBT2));
m_oo_list.push_back(HackEntry<OO_Ptr>(CRC::MajokkoALaMode2, CRC::RegionCount, &GSRendererHW::OO_MajokkoALaMode2));
@ -640,13 +750,12 @@ protected:
TEX0.TBP0 = context->FRAME.Block();
TEX0.TBW = context->FRAME.FBW;
TEX0.PSM = context->FRAME.PSM;
GSTextureCache::Target* rt = m_tc->LookupTarget(TEX0, m_width, m_height, GSTextureCache::RenderTarget, true);
TEX0.TBP0 = context->ZBUF.Block();
TEX0.TBW = context->FRAME.FBW;
TEX0.PSM = context->ZBUF.PSM;
GSTextureCache::Target* ds = m_tc->LookupTarget(TEX0, m_width, m_height, GSTextureCache::DepthStencil, m_context->DepthWrite());
GSTextureCache::Source* tex = NULL;

View File

@ -1913,6 +1913,7 @@ struct GSFrameInfo
};
typedef bool (*GetSkipCount)(const GSFrameInfo& fi, int& skip);
CRC::Region g_crc_region = CRC::NoRegion;
bool GSC_Okami(const GSFrameInfo& fi, int& skip)
{
@ -1955,7 +1956,14 @@ bool GSC_MetalGearSolid3(const GSFrameInfo& fi, int& skip)
}
else if(!fi.TME && fi.FBP == fi.TBP0 && fi.FBP == 0x2000 && fi.FPSM == PSM_PSMCT32 && fi.TPSM == PSM_PSMCT24)
{
skip = 119;
if(g_crc_region == CRC::US || g_crc_region == CRC::JP || g_crc_region == CRC::KO)
{
skip = 119; //ntsc
}
else
{
skip = 136; //pal
}
}
}
@ -2079,6 +2087,10 @@ bool GSC_SoTC(const GSFrameInfo& fi, int& skip)
// Not needed anymore? What did it fix anyway? (rama)
/*if(skip == 0)
{
if(fi.TME && (fi.FBP == 0x03d00 || fi.FBP == 0x03d80) && fi.FPSM == PSM_PSMCT32 && fi.TBP0 == 0x03fc0 && fi.TPSM == PSM_PSMCT24)
{
//skip = 48; //stops light sources
}
if(fi.TME && fi.FBP == 0x02b80 && fi.FPSM == PSM_PSMCT24 && fi.TBP0 == 0x01e80 && fi.TPSM == PSM_PSMCT24)
{
skip = 9;
@ -2150,9 +2162,13 @@ bool GSC_GT4(const GSFrameInfo& fi, int& skip)
{
if(skip == 0)
{
if(fi.TME && (fi.FBP == 0x03440 || fi.FBP >= 0x03e00) && fi.FPSM == PSM_PSMCT32 && (fi.TBP0 == 0x00000 || fi.TBP0 == 0x01400) && fi.TPSM == PSM_PSMT8)
if(fi.TME && fi.FBP >= 0x02f00 && fi.FPSM == PSM_PSMCT32 && (fi.TBP0 == 0x00000 || fi.TBP0 == 0x01180 /*|| fi.TBP0 == 0x01a40*/) && fi.TPSM == PSM_PSMT8) //TBP0 0x1a40 progressive
{
skip = 880;
skip = 770; //ntsc, progressive 1540
}
if(g_crc_region == CRC::EU && fi.TME && fi.FBP >= 0x03400 && fi.FPSM == PSM_PSMCT32 && (fi.TBP0 == 0x00000 || fi.TBP0 == 0x01400 ) && fi.TPSM == PSM_PSMT8)
{
skip = 880; //pal
}
else if(fi.TME && (fi.FBP == 0x00000 || fi.FBP == 0x01400) && fi.FPSM == PSM_PSMCT24 && fi.TBP0 >= 0x03420 && fi.TPSM == PSM_PSMT8)
{
@ -2657,7 +2673,7 @@ bool GSC_Sly3(const GSFrameInfo& fi, int& skip)
{
if(skip == 0)
{
if(fi.TME && (fi.FBP == 0x00000 || fi.FBP == 0x00700) && fi.FPSM == fi.TPSM && (fi.TBP0 == 0x00000 || fi.TBP0 == 0x00700) && fi.TPSM == PSM_PSMCT16)
if(fi.TME && (fi.FBP == 0x00000 || fi.FBP == 0x00700 || fi.FBP == 0x00a80 || fi.FBP == 0x00e00) && fi.FPSM == fi.TPSM && (fi.TBP0 == 0x00000 || fi.TBP0 == 0x00700 || fi.TBP0 == 0x00a80 || fi.TBP0 == 0x00e00) && fi.TPSM == PSM_PSMCT16)
{
skip = 1000;
}
@ -3039,6 +3055,49 @@ bool GSC_MidnightClub3(const GSFrameInfo& fi, int& skip)
return true;
}
bool GSC_SpyroNewBeginning(const GSFrameInfo& fi, int& skip)
{
if(skip == 0)
{
if(fi.TME && fi.FBP == fi.TBP0 && fi.FPSM == fi.TPSM && fi.TBP0 == 0x034a0 && fi.TPSM == PSM_PSMCT16)
{
skip = 2;
}
}
return true;
}
bool GSC_SpyroEternalNight(const GSFrameInfo& fi, int& skip)
{
if(skip == 0)
{
if(fi.TME && fi.FBP == fi.TBP0 && fi.FPSM == fi.TPSM && (fi.TBP0 == 0x034a0 ||fi.TBP0 == 0x035a0 || fi.TBP0 == 0x036e0) && fi.TPSM == PSM_PSMCT16)
{
skip = 2;
}
}
return true;
}
bool GSC_TalesOfLegendia(const GSFrameInfo& fi, int& skip)
{
if(skip == 0)
{
if(fi.TME && (fi.FBP == 0x3f80 || fi.FBP == 0x03fa0) && fi.FPSM == PSM_PSMCT32 && fi.TPSM == PSM_PSMT8)
{
skip = 3; //3, 9
}
if(fi.TME && fi.FBP == 0x3800 && fi.FPSM == PSM_PSMCT32 && fi.TPSM == PSM_PSMZ32)
{
skip = 2;
}
}
return true;
}
bool GSState::IsBadFrame(int& skip, int UserHacks_SkipDraw)
{
@ -3124,11 +3183,15 @@ bool GSState::IsBadFrame(int& skip, int UserHacks_SkipDraw)
map[CRC::BurnoutRevenge] = GSC_Burnout;
map[CRC::BurnoutDominator] = GSC_Burnout;
map[CRC::MidnightClub3] = GSC_MidnightClub3;
map[CRC::SpyroNewBeginning] = GSC_SpyroNewBeginning;
map[CRC::SpyroEternalNight] = GSC_SpyroEternalNight;
map[CRC::TalesOfLegendia] = GSC_TalesOfLegendia;
}
// TODO: just set gsc in SetGameCRC once
GetSkipCount gsc = map[m_game.title];
g_crc_region = m_game.region;
if(gsc && !gsc(fi, skip))
{