Quote:
Originally Posted by Mrs Beanbag
Blitting the entire playfield is completely unnecessary... you just shift the start of screen memory one word to the right and keep on going. As long as you have a little extra Chip RAM to move into, the image just wraps round and round. Remember memory is always linear, the 2 dimensions of the screen are an illusion.
|
Thanks for your clarifications. How would this work for large maps? If, say, I keep moving screen memory to the right, would I not eventually reach the boundaries of allocated memory, independent of representation?
Quote:
Originally Posted by Mrs Beanbag
if the other sprites can also be updated at 50fps, there is no problem. Although Mr Beanbag does experience this problem, because the hardware scrolling has granularity of 1/4 pixel horizontally, and of course bobs are restricted to full pixel motions, so sometimes enemy sprites that are chasing the player can appear to vibrate slightly. But 1/4 pixel scrolling is not possible on OCS anyway.
|
Thanks again for enlightening me! I hadn't the faintest clue that hardware supported a granularity of 1/4 pixel horizontally. So I might be misunderstanding your answer, but the problem I experienced was not due to spatial resolution but disparity in temporal updates. In particular, the player camera logic was running as an ISR at 50 Hz, decoupled from the rendering, which ran at 25 Hz. The ISR also updated the registers that controlled the start of screen memory and per-pixel scrolling; this made up for the slower map-drawing updates, and kept the scrolling running at 50 Hz. The sprites on the other hand updated during map drawing cycles, at 25 Hz, so every other frame they would move with the scrolling background, giving the impression they were somehow vibrating.
Caveat: Only true if memory serves me well.