TomHarte / Isometric-Ray-Cast

Zero-overdraw isometric graphics for the ZX Spectrum, featuring the Ant Attack map.
30 stars 0 forks source link

Moves a shift into the final tile loop, killing `fix_up`. #4

Closed TomHarte closed 3 years ago

TomHarte commented 3 years ago

Even and odd rows now use the same bits for triangle colour, adding an rra per 8x8 tile but eliminating an sr (hl) per triangle (plus loop counting) during isometric axis-aligned scrolls.

Given an unrelated further optimisation of draw_tiles this pull request saves around 25,000 cycles for those. Which right now is about one extra frame per second — from ~13 to ~14.

It's also a few hundred bytes smaller.