comparison vdp.c @ 454:e9b6fe443bf2

Fix per-column scrolling bug
author Mike Pavone <pavone@retrodev.com>
date Mon, 02 Sep 2013 01:02:18 -0700
parents b491df8bdbc0
children c49ecf575784 788ba843a731
comparison
equal deleted inserted replaced
453:b491df8bdbc0 454:e9b6fe443bf2
617 } 617 }
618 if (context->double_res) { 618 if (context->double_res) {
619 vscroll <<= 1; 619 vscroll <<= 1;
620 vscroll |= 1; 620 vscroll |= 1;
621 } 621 }
622 vscroll &= (context->vsram[(context->regs[REG_MODE_3] & BIT_VSCROLL ? column : 0) + vsram_off] + line); 622 vscroll &= (context->vsram[(context->regs[REG_MODE_3] & BIT_VSCROLL ? (column-2)&63 : 0) + vsram_off] + line);
623 context->v_offset = vscroll & v_offset_mask; 623 context->v_offset = vscroll & v_offset_mask;
624 //printf("%s | line %d, vsram: %d, vscroll: %d, v_offset: %d\n",(vsram_off ? "B" : "A"), line, context->vsram[context->regs[REG_MODE_3] & 0x4 ? column : 0], vscroll, context->v_offset); 624 //printf("%s | line %d, vsram: %d, vscroll: %d, v_offset: %d\n",(vsram_off ? "B" : "A"), line, context->vsram[context->regs[REG_MODE_3] & 0x4 ? column : 0], vscroll, context->v_offset);
625 vscroll >>= vscroll_shift; 625 vscroll >>= vscroll_shift;
626 uint16_t hscroll_mask; 626 uint16_t hscroll_mask;
627 uint16_t v_mul; 627 uint16_t v_mul;