View Single Post
Old 31 August 2018, 18:30   #13
Leffmann
 
Join Date: Jul 2008
Location: Sweden
Posts: 2,269
I don't think there's any sure answer to this, it will vary not just from one algorithm to another, but with the exact implementation of it.

What I do is use a FILO queue to keep track of horizontal spans. I remove one item from the queue and fill in the whole span, then search across it to find all individual spans above and below, and add them to the queue. When the queue is empty, the whole area is filled in.

For most test images the queue rarely grows larger than a dozen items, even if I draw a lot of "jaggies", but I'm not sure how to stress-test it properly.
Leffmann is offline  
 
Page generated in 0.04715 seconds with 11 queries