Optimization: replace slow VideoGetVbl() with fast NTSC_VideoIsVbl()

This commit is contained in:
michaelangel007 2015-01-02 21:28:01 -08:00
parent f36073beb5
commit b96b3fe1d4

View File

@ -897,8 +897,8 @@ BYTE VideoCheckMode (WORD, WORD address, BYTE, BYTE, ULONG uExecutedCycles)
BYTE VideoCheckVbl (WORD, WORD, BYTE, BYTE, ULONG uExecutedCycles) BYTE VideoCheckVbl (WORD, WORD, BYTE, BYTE, ULONG uExecutedCycles)
{ {
bool bVblBar = VideoGetVbl(uExecutedCycles); //bool bVblBar = VideoGetVbl(uExecutedCycles);
//bool bVblBar = NTSC_VideoIsVbl(); bool bVblBar = NTSC_VideoIsVbl();
BYTE r = KeybGetKeycode(); BYTE r = KeybGetKeycode();
return (r & ~0x80) | (bVblBar ? 0x80 : 0); return (r & ~0x80) | (bVblBar ? 0x80 : 0);