23 September 2018, 22:13 | #1 |
Registered User
Join Date: Mar 2012
Location: UK
Posts: 1,893
|
Smooth fast scrolling?
Something I have always wondered about is how to do smooth fast scrolling.
If we assume the game runs at 50 fps and scrolls one pixel per frame then it can scroll 50 pixels per second. At 50 fps it will take 6 seconds to scroll across the screen. How do games do quicker scrolling? Do they just scroll more pixels at one time? And where does AGA 1/4 pixel scrolling come in - can AGA scroll between pixels and wouldn't this be even slower???? Confused - I know I am! |
23 September 2018, 22:31 | #2 | ||
Registered User
Join Date: Jul 2015
Location: The Netherlands
Posts: 3,408
|
Quote:
Quote:
Well, it's all about smooth scrolling - if you want to scroll a screen slower than 1 pixel per frame, it may start looking slightly jerky. But with AGA, such a scroll can still be done fully smoothly (as long as the speed >= 1/4 of a lores pixel per frame). Another way to make use of AGA scrolling is when scrolling speeds change. The AGA 1/4 pixel intervals allow for a smoother curve when accelerating or slowing down, which is (again) smoother to look at. |
||
23 September 2018, 23:16 | #3 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,334
|
Yep, the subpixel scrolling allows you to move at a much more finely grained range of speeds. So even if 1 pixel per frame is too slow, maybe 2.5 pixels per frame is just right. Without the subpixel scrolling, you would scroll 2 pixels in one frame, 3 pixels in the next, 2 pixels in the next and so on, which will be awful.
Ultimately, it's not about drawing more quickly, it's about moving the correct distance in one frame. Once you move exactly the same distance in each frame, it will appear perfectly smooth, no matter how fast or slow. Gradual acceleration will also benefit as mentioned, again thanks to a much finer range of speeds that allow something like "anti-aliasing" of the movement. |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
smooth scrolling.is it possible? | kirk | support.WinUAE | 30 | 01 October 2007 13:57 |
smooth scrolling | sink | support.WinUAE | 3 | 20 July 2007 01:16 |
Smooth scrolling with WinUAE? | Tony Landais | support.WinUAE | 13 | 30 May 2007 03:55 |
Smooth scrolling in 100Hz | Kintaro | support.WinUAE | 21 | 27 February 2003 15:55 |
Just can't get smooth scrolling | Bobbin | support.WinUAE | 0 | 23 November 2002 00:52 |
|
|