mirror of
https://github.com/reactos/reactos.git
synced 2024-09-30 14:37:45 +00:00
[NTVDM]
Reverse the HSYNC/VSYNC polarity when it should be reversed. svn path=/trunk/; revision=67746
This commit is contained in:
parent
9b1cceafb1
commit
08ec785c24
|
@ -1393,15 +1393,21 @@ static BYTE WINAPI VgaReadPort(USHORT Port)
|
|||
case VGA_INSTAT1_READ_COLOR:
|
||||
{
|
||||
BYTE Result = 0;
|
||||
BOOLEAN Vsync = InVerticalRetrace;
|
||||
BOOLEAN Hsync = InHorizontalRetrace;
|
||||
|
||||
/* Reset the AC latch */
|
||||
VgaAcLatch = FALSE;
|
||||
|
||||
/* Reverse the polarity, if needed */
|
||||
if (VgaMiscRegister & VGA_MISC_VSYNCP) Vsync = !Vsync;
|
||||
if (VgaMiscRegister & VGA_MISC_HSYNCP) Hsync = !Hsync;
|
||||
|
||||
/* Set a flag if there is a vertical or horizontal retrace */
|
||||
if (InVerticalRetrace || InHorizontalRetrace) Result |= VGA_STAT_DD;
|
||||
if (Vsync || Hsync) Result |= VGA_STAT_DD;
|
||||
|
||||
/* Set an additional flag if there was a vertical retrace */
|
||||
if (InVerticalRetrace) Result |= VGA_STAT_VRETRACE;
|
||||
if (Vsync) Result |= VGA_STAT_VRETRACE;
|
||||
|
||||
/* Clear the flags */
|
||||
InHorizontalRetrace = InVerticalRetrace = FALSE;
|
||||
|
|
Loading…
Reference in a new issue