GSDX: Add an option to disable NTSC saturation

v2: convert it into a member variable.
This commit is contained in:
Akash 2016-04-06 10:21:17 +05:30
parent da9577076c
commit 69c9a3d793
2 changed files with 8 additions and 7 deletions

View File

@ -44,6 +44,7 @@ GSState::GSState()
{ {
m_nativeres = theApp.GetConfig("upscale_multiplier",1) == 1; m_nativeres = theApp.GetConfig("upscale_multiplier",1) == 1;
m_mipmap = !!theApp.GetConfig("mipmap", 1); m_mipmap = !!theApp.GetConfig("mipmap", 1);
m_NTSC_Saturation = !!theApp.GetConfig("NTSC_Saturation", true);
s_n = 0; s_n = 0;
s_dump = !!theApp.GetConfig("dump", 0); s_dump = !!theApp.GetConfig("dump", 0);
@ -379,11 +380,10 @@ GSVector4i GSState::GetFrameRect(int i)
int w = r.width(); int w = r.width();
int h = r.height(); int h = r.height();
// NTSC: Saturate higher height values for games which have CRTC width lower than 640. // Limit games to standard NTSC resolutions. games with 512X512 (PAL resolution) on NTSC video mode produces black border on the bottom.
// Some NTSC mode games request higher height values for accurate display size / position when width is 640 // 512 X 448 is the resolution generally used by NTSC, saturating the height value seems to get rid of the black borders.
// Testcases : PS logo (640x512) , Resident Evil:CVX (640x480). potentially more test cases... // Though it's quite a bad hack as it affects binaries which are patched to run on a non-native video mode.
if (Vmode_NTSC && h > 448 && w < 640 && m_NTSC_Saturation)
if (Vmode_NTSC && h > 448 && w < 640)
h = 448; h = 448;
if (m_regs->SMODE2.INT && m_regs->SMODE2.FFMD && h > 1) if (m_regs->SMODE2.INT && m_regs->SMODE2.FFMD && h > 1)

View File

@ -195,12 +195,13 @@ public:
GSDrawingContext* m_context; GSDrawingContext* m_context;
GSPerfMon m_perfmon; GSPerfMon m_perfmon;
uint32 m_crc; uint32 m_crc;
CRC::Game m_game;
GSDump m_dump;
int m_options; int m_options;
int m_frameskip; int m_frameskip;
bool m_crcinited; bool m_crcinited;
bool m_framelimit; bool m_framelimit;
CRC::Game m_game; bool m_NTSC_Saturation;
GSDump m_dump;
bool m_nativeres; bool m_nativeres;
bool m_mipmap; bool m_mipmap;