![]() |
![]() |
#101 |
Lemon. / Core Design
Join Date: Mar 2016
Location: Tier 5
Posts: 1,219
|
Smooth horizontal scrolling on the ST in games such as Chuck Rock (probably Wolfchild, Carvup etc.. too), used preshifted block pairs. This meant that you had to be careful about the layout of tiles on your map, but it used the minimum necessary preshifted data, so it didn't take a huge amount of memory to store.
You could also build the code for each line (that was called 16 times), to fetch the data, and move it into screen memory efficiently. This is effectively how games like Cobra on the Spectum achieved smooth scrolling too. |
![]() |
![]() |
#102 |
Lemon. / Core Design
Join Date: Mar 2016
Location: Tier 5
Posts: 1,219
|
|
![]() |
![]() |
#103 |
Registered User
Join Date: Sep 2022
Location: Eastbourne
Posts: 1,210
|
Should it have said "if you want to scroll horizontally in less than 16 pixel jumps without making significant design compromises if designing for an ST, or without cutting back on detail if converting from elsewhere you need to allocate duplicate 32k screens with preshifted tiles for however many pixels you really want to scroll". (my italics)?
|
![]() |
![]() |
#104 | |
Inviyya Dude!
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,806
|
Quote:
Could you explain that a bit more? For the case if I ever try to code an ST game, that is... ![]() Love to read about clever coding techniques. |
|
![]() |
![]() |
#105 |
Registered User
Join Date: Feb 2008
Location: .
Posts: 110
|
+1
In a 16 pixel-wide block, if you start preshifting a tile, you have to start including in those 16 pixels the next possible tile(S) existing to the right, the ones that will be displayed right after the current tile on the same line, because their preshifting "bleeds" into the current tile. If you don't do that, you will have a horrible discontinuity. That means you have to consider all the possible associations of TileA-TileB on screen for 32 pixels, and because memory is not unlimited, you can only have a limited number of tile association for your game with that technique, which sets constraints for level artists. If you don't want to have that constraint for preshifted tiles on ST, you will have to draw 2 tiles per 16-pixel block, using an OR each time for the second tile within your 16-pixel block, which will more than double the cost of drawing those tiles but will let you arrange them in any way you want. Last edited by Keops/Equinox; 09 November 2022 at 14:48. |
![]() |
![]() |
#106 |
Registered User
Join Date: Feb 2009
Location: london/england
Posts: 1,347
|
|
![]() |
![]() |
#107 |
Registered User
Join Date: Feb 2009
Location: london/england
Posts: 1,347
|
I have just checked out the longplay of Turrican 2 on the ST and it has the parallax scrolling shmup level. OK it's not as fluid as the C64 version but it is impressive.
I'd give it a go but ST cracks rarely have decent trainer options, 99% of the time it's useless unlimited lives/credits. |
![]() |
![]() |
#108 | |
Inviyya Dude!
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,806
|
Quote:
![]() I am a bit dabbling in ST coding at the moment, and would love to find out how some of that tricky stuff worked.. What do you mean by "block pairs" ![]() Plus that "You could also build the code for each line (that was called 16 times), to fetch the data" sounds quite mysterious to me... ![]() |
|
![]() |
![]() |
#109 | |
Registered User
Join Date: May 2023
Location: Norwich
Posts: 527
|
Quote:
One trick to make this more performant is to only allow certain transitions between tiles. That way you can use pre-shifted versions that already contain the merged together data and so it can be drawn quicker. You basically generate specific code for the exact data you're going to generate. So, for example, a sequence of instructions to draw tile A three times, then tile X, then tile Y etc..This means you have to make less decisions, because each row of tiles can use the same instructions rather than checking the tile map each time to figure out what to draw next. It's not for the feint hearted and requires solid optimization to be entirely worthwhile. |
|
![]() |
![]() |
#110 |
Registered User
Join Date: Nov 2021
Location: Utrecht/Netherlands
Posts: 340
|
Which chips in Amiga do and help for smooth scrolling? As far as I know copper can change the number of colors in screen only
|
![]() |
![]() |
#111 |
Inviyya Dude!
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,806
|
|
![]() |
![]() |
#112 | |
Inviyya Dude!
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,806
|
Quote:
Thanks... ![]() |
|
![]() |
![]() |
#113 | |
Lemon. / Core Design
Join Date: Mar 2016
Location: Tier 5
Posts: 1,219
|
Quote:
The colour registers are just 32 of those registers. There's also (among many others), bitplane pointers, bitplane control registers, sprite registers, audio registers etc... |
|
![]() |
![]() |
#114 | |
Going nowhere
Join Date: Oct 2001
Location: United Kingdom
Age: 50
Posts: 9,035
|
Quote:
It can access most of the hardware registers, triggering blits, interrupts, screen mode changes, sprite multiplexing, sample triggering, changing bitplane pointers, literally any hardware register that can be written to, can be done by the copper. It's what makes the Amiga.......Amiga! |
|
![]() |
![]() |
#115 |
Registered User
Join Date: May 2023
Location: essex
Posts: 635
|
I presume on Amiga you can move the screen memory pointer to scroll the screen around a large bitmap 1 pixel at a time?
|
![]() |
![]() |
#116 | |
Going nowhere
Join Date: Oct 2001
Location: United Kingdom
Age: 50
Posts: 9,035
|
Quote:
Scrolling vertically can be done by changing the bitplane pointers, so yes you can easily scroll around a large Bitmap and the Amiga isn't remotely being stressed doing it. |
|
![]() |
Currently Active Users Viewing This Thread: 2 (1 members and 1 guests) | |
modrobert |
Thread Tools | |
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
9 Lives - smooth scrolling | punkrulesok | support.Games | 14 | 22 November 2018 22:24 |
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 |
Just can't get smooth scrolling | Bobbin | support.WinUAE | 0 | 23 November 2002 00:52 |
|
|