Mercurial > repos > blastem
changeset 2465:b0408f38f464
Add missing mask to vscroll calculation in Mode 4
author | Michael Pavone <pavone@retrodev.com> |
---|---|
date | Sat, 24 Feb 2024 11:53:44 -0800 |
parents | f9d5c137c74b |
children | b5640ac9aea9 |
files | vdp.c |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/vdp.c Fri Feb 23 23:09:20 2024 -0800 +++ b/vdp.c Sat Feb 24 11:53:44 2024 -0800 @@ -1371,8 +1371,10 @@ uint32_t vscroll = line; if (column < 24 || !(context->regs[REG_MODE_1] & BIT_VSCRL_LOCK)) { vscroll += context->regs[REG_Y_SCROLL]; + vscroll &= 511; } if (vscroll > 223) { + //TODO: support V28 and V30 for SMS2/GG VDPs vscroll -= 224; } address += (vscroll >> 3) * 2 * 32;