> I was thinking if you do line-by-line front-to-back rendering, you could quite
> easily avoid drawing the invisible background.
> Just a thought...
Yes i think that was the main thing i was thinking as well, I just didn't realise it had a name "front-to-back" ;-)
So basically, for each line:
- calculate the tile values for Plane A
- Render Plane A high tiles
- calculate the tile values for Plane B which are still visible
- Render Plane B high tiles clipping to uncovered pixels
- Render Plane A low tiles clipping to uncovered pixels
- Render Plane B low tiles clipping to uncovered pixels
Making sure to skip completely blank tiles
Do you reckon that's pretty much as fast as it gets?
You learn something old everyday...