+ /* This should always return a plane 0 address for read mode 1 */
+ VideoAddress = VgaTranslateReadAddress(Address + i);
+
+ for (j = 0; j < VGA_NUM_BANKS; j++)
+ {
+ /* Don't consider ignored banks */
+ if (!(VgaGcRegisters[VGA_GC_COLOR_IGNORE_REG] & (1 << j))) continue;
+
+ if (VgaGcRegisters[VGA_GC_COLOR_COMPARE_REG] & (1 << j))
+ {
+ /* Comparing with 11111111 */
+ Result &= VgaMemory[j * VGA_BANK_SIZE + LOWORD(VideoAddress)];
+ }
+ else
+ {
+ /* Comparing with 00000000 */
+ Result &= ~(VgaMemory[j * VGA_BANK_SIZE + LOWORD(VideoAddress)]);
+ }
+ }
+
+ /* Copy the value to the buffer */
+ BufPtr[i] = Result;
+ }