# HG changeset patch # User Mike Pavone # Date 1378832112 25200 # Node ID 5677c053edd662f6ad8f25aff794f0beec002c79 # Parent 6221f8f534fa4f56ba8b22f47040f5a4fcdb7ef2 Fix timing of backdrop rendering when the display is turned off diff -r 6221f8f534fa -r 5677c053edd6 vdp.c --- a/vdp.c Tue Sep 10 00:30:39 2013 -0700 +++ b/vdp.c Tue Sep 10 09:55:12 2013 -0700 @@ -1211,14 +1211,20 @@ line -= 1; int starti = -1; if (context->latched_mode & BIT_H40) { - if (slot >= 50 && slot < 210) { - uint32_t x = (slot-50)*2; + if (slot >= 55 && slot < 210) { + uint32_t x = (slot-55)*2; starti = line * 320 + x; + } else if (slot < 5) { + uint32_t x = (slot + 155)*2; + starti = (line-1)*320 + x; } } else { - if (slot >= 43 && slot < 171) { - uint32_t x = (slot-43)*2; + if (slot >= 48 && slot < 171) { + uint32_t x = (slot-48)*2; starti = line * 320 + x; + } else if (slot < 5) { + uint32_t x = (slot + 123)*2; + starti = (line-1)*320 + x; } } if (starti >= 0) {