mirror of https://github.com/PCSX2/pcsx2.git
GSDX: Remove dubious/unnecessary hacks
* Silent Hill 2 doesn't need the CRC hack * GSRenderer: no need to explicitly set bottom value for r. * Texture Cache: Removed a check which couldn't possibly enter true branch.
This commit is contained in:
parent
69c9a3d793
commit
a1b0ae467e
|
@ -212,15 +212,6 @@ bool GSRenderer::Merge(int field)
|
|||
if(!en[i] || !tex[i]) continue;
|
||||
|
||||
GSVector4i r = fr[i];
|
||||
|
||||
// overscan hack
|
||||
|
||||
if(dr[i].height() > 512) // hmm
|
||||
{
|
||||
int y = GetDeviceSize(i).y;
|
||||
r.bottom = r.top + y;
|
||||
}
|
||||
|
||||
GSVector4 scale = GSVector4(tex[i]->GetScale()).xyxy();
|
||||
|
||||
src[i] = GSVector4(r) * scale / GSVector4(tex[i]->GetSize()).xyxy();
|
||||
|
|
|
@ -429,21 +429,9 @@ GSVector2i GSState::GetDeviceSize(int i)
|
|||
|
||||
//Fixme : Just slightly better than the hack above
|
||||
if(m_regs->SMODE2.INT && m_regs->SMODE2.FFMD && h > 1)
|
||||
{
|
||||
if (IsEnabled(0) || IsEnabled(1))
|
||||
{
|
||||
h >>= 1;
|
||||
}
|
||||
}
|
||||
|
||||
//Fixme: These games elude the code above, worked with the old hack
|
||||
else if(m_game.title == CRC::SilentHill2 || m_game.title == CRC::SilentHill3)
|
||||
{
|
||||
h /= 2;
|
||||
}
|
||||
h >>= 1;
|
||||
|
||||
return GSVector2i(w, h);
|
||||
|
||||
}
|
||||
|
||||
bool GSState::IsEnabled(int i)
|
||||
|
|
|
@ -368,7 +368,7 @@ GSTextureCache::Target* GSTextureCache::LookupTarget(const GIFRegTEX0& TEX0, int
|
|||
{
|
||||
int multiplier = m_renderer->GetUpscaleMultiplier();
|
||||
|
||||
if(multiplier > 1) // it's limited to a maximum of 4 on reading the config
|
||||
if(multiplier > 1)
|
||||
{
|
||||
dst->m_texture->SetScale(GSVector2((float)multiplier, (float)multiplier));
|
||||
}
|
||||
|
@ -379,11 +379,6 @@ GSTextureCache::Target* GSTextureCache::LookupTarget(const GIFRegTEX0& TEX0, int
|
|||
int ww = (int)(fr.left + m_renderer->GetDisplayRect().width());
|
||||
int hh = (int)(fr.top + m_renderer->GetDisplayRect().height());
|
||||
|
||||
if(hh <= m_renderer->GetDeviceSize().y / 2)
|
||||
{
|
||||
hh *= 2;
|
||||
}
|
||||
|
||||
// Gregory: I'm sure this sillyness is related to the usage of a 32bits
|
||||
// buffer as a 16 bits format. In this case the height of the buffer is
|
||||
// multiplyed by 2 (Hence a scissor bigger than the RT)
|
||||
|
@ -395,7 +390,7 @@ GSTextureCache::Target* GSTextureCache::LookupTarget(const GIFRegTEX0& TEX0, int
|
|||
hh = 512;
|
||||
}
|
||||
|
||||
if(ww > 0 && hh > 0)
|
||||
if(ww && hh)
|
||||
{
|
||||
dst->m_texture->SetScale(GSVector2((float)w / ww, (float)h / hh));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue