Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
ScrollLeft function scrolling more than 1 pixels left
#2
Yes, thatÅ› right. For horizontal scroll, it's very difficult to do a pixel precise frame scroll. It does it in 8 pixels wide blocks. Doing it pixel perfect, due to ZX Spectrum architecture, would be really slow. I still can provide you a scroll routine that does exactly that, but be aware that it will be REALLY slow.

For vertical scroll this does not happen and it's pixel perfect.

A simple solution is to place your rectangle in an aligned zone.
You can draw the box frame out of the inner part that will be scrolled:
Code:
square(7, 15, 80, 60, 6)
This should work

One more thing: Float is REALLY slow and expensive. Consider using Fixed instead of Float and only if necessary. Most of the time you will need just Uinteger or Ubyte values.
Reply


Messages In This Thread
RE: SrollLeft function scrolling more than 1 pixels left - by boriel - 03-03-2024, 09:17 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)