Horizontal Cell Scroll + Vertical Plane Scroll

For anything related to VDP (plane, color, sprite, tiles)

Moderators: BigEvilCorporation, Mask of Destiny

Post Reply
Manveru
Very interested
Posts: 85
Joined: Wed Sep 05, 2012 3:30 pm

Horizontal Cell Scroll + Vertical Plane Scroll

Post by Manveru » Mon Dec 02, 2019 9:43 am

I come from this topic but i do not know very well how it works and if the same applies to horizontal scroll:
viewtopic.php?f=22&t=737

In short: i have a cell (tile) scroll for a 36 tile height background. When vertical scroll is 0, then the background horizontally scrolls from tile line 0 to 27 as you can expect... but if you move down the vertical scroll for example 3 pixels, then the cell line 0 (probably it is now the cell -1) is shown partially only 5 pixels, and a new 28 line (probably the new 27) is partially shown with 3 pixel.

My question is how do you scroll 29 lines when the cell scroll only lets you scrolling 28. In the above topic the leftmost column seems to scroll with the same offset of the rightmost column, but i do not fully understand how to make it work, or if the horizontal scroll works the same as the vertical one "looping" the offset from bottommost line to the upmost.

Thanks.
The man who moves a mountain begins by carrying away small stones. Confucius, 551-479 BC

Miquel
Very interested
Posts: 514
Joined: Sat Jul 30, 2016 12:33 am

Re: Horizontal Cell Scroll + Vertical Plane Scroll

Post by Miquel » Mon Dec 02, 2019 10:56 pm

Your post is extremely confusing, not sure I understood it at all, but let’s give it a try.

You can only scroll 28 tiles because that’s the max resolution on NTSC (28 * 8 = 224).
HELP. Spanish TVs are brain washing people to be hostile to me.

Manveru
Very interested
Posts: 85
Joined: Wed Sep 05, 2012 3:30 pm

Re: Horizontal Cell Scroll + Vertical Plane Scroll

Post by Manveru » Tue Dec 03, 2019 9:55 am

Miquel wrote:
Mon Dec 02, 2019 10:56 pm
Your post is extremely confusing, not sure I understood it at all, but let’s give it a try.

You can only scroll 28 tiles because that’s the max resolution on NTSC (28 * 8 = 224).
The questin was if it is possible to make properly a horizontal cell scroll when the vertical scroll is moving. Horizontal cell scroll seems to desyncronize when you move vertical scroll a value % 8 != 0. It is like if you move down 4 pixels, what at 0 scrolled horizontal pixels 0-7 at cell 0, now moves pixels 4-11
The man who moves a mountain begins by carrying away small stones. Confucius, 551-479 BC

Miquel
Very interested
Posts: 514
Joined: Sat Jul 30, 2016 12:33 am

Re: Horizontal Cell Scroll + Vertical Plane Scroll

Post by Miquel » Thu Dec 05, 2019 8:38 pm

Could it be that vdp hardware applies first vertical scroll and only then horizontal? If that’s the case, since there is no way to exchange priorities, I don’t think there is a solution, one of both scrollings has to be first.
HELP. Spanish TVs are brain washing people to be hostile to me.

Manveru
Very interested
Posts: 85
Joined: Wed Sep 05, 2012 3:30 pm

Re: Horizontal Cell Scroll + Vertical Plane Scroll

Post by Manveru » Fri Dec 06, 2019 9:17 am

Miquel wrote:
Thu Dec 05, 2019 8:38 pm
Could it be that vdp hardware applies first vertical scroll and only then horizontal? If that’s the case, since there is no way to exchange priorities, I don’t think there is a solution, one of both scrollings has to be first.
it is possible and i also can not find a solution so we decided to set horizontal scroll to scanline mode. it is slower but.... That explains why in Thunder Force 4 they use scanline scroll even when the background only uses tile parallax, except in Air Raid where there is not vertical scroll and cell parallax is used.
The man who moves a mountain begins by carrying away small stones. Confucius, 551-479 BC

Post Reply