Skip to content
Permalink
Browse files

Fixed tile off by one and some timing issues

  • Loading branch information
davecom committed Jul 19, 2018
1 parent 96ad1fc commit 53db1fab2d4489ecab18ac988ae6d2d06dbcc944
Showing with 1 addition and 1 deletion.
  1. +1 −1 Sources/DDPPU.c
@@ -92,7 +92,7 @@ inline void ppu_step() {
byte color = ((tile_data >> 32) >> ((7 - X) * 4)) & 0x0F;
draw_pixel(cycle, scanline, color);
}
if (scanline < 240 && (cycle < 256 || (cycle >= 321 && cycle <= 336))) {
if ((scanline < 240 || scanline == 261) && ((cycle > 0 && cycle < 256) || (cycle >= 321 && cycle <= 336))) {

// prepare for next render
tile_data <<= 4;

0 comments on commit 53db1fa

Please sign in to comment.
You can’t perform that action at this time.