View Single Post
Old 16 December 2019, 17:35   #11
deimos
Registered User

 
Join Date: Jul 2018
Location: France
Posts: 545
Quote:
Originally Posted by a/b View Post
Well, that's a different picture than the one in the first post.

In any case, you wouldn't have do draw that line if you were using the FCI bit. When you are doing filled poly clipping, you normally draw a vertical line on the right-hand border when a line-segment is >= width, because blitter works right to left, and skip the left-hand border entirely (don't draw anything when < 0). So you just either change your poly-clipper to optionally skip those lines, or make two routines if performance is an issue.
Or is there another 'hidden' constraint?
If we're talking about the same thing, that line is to turn off the fill that's FCI carried in, so it doesn't work in the example I gave.

Changing my poly-clipper to skip those lines sounds essentially the same as splitting the blit into two, one where the diagonal line exists, as a fill, and a second as just a clear, below that.

The 'hidden' constraints are only that I'm trying to make this part of my screen clearing process, so I was aiming for a single blit for the bitplane that is my sky / ground, i.e. all the sky bits are set to 0 and all the ground bits are set to 1. The other 3 bitplanes have all been set to 0 in a previous blit.

The set up I've done to get to this point is to partially clip the screen rectangle against the ground plane - if I see that two adjacent corners are not eith both above or both below the ground then I know there's an intersection to calculate. I don't get a polygon as such, I just know which edges have intersections and that's the horizon line, an I have to fill / clear above / below it. As it's part of my screen clearing I want both filling and clearing to happen.

I can post code if it helps more than it hurts.
deimos is offline  
 
Page generated in 0.06831 seconds with 11 queries