[Tioga-users] monochrome image

Bill Paxton paxton at kitp.ucsb.edu
Tue Dec 12 12:54:53 EST 2006


On Dec 12, 2006, at 8:13 AM, Edwin wrote:

> I'm actually thinking about using make_contour and then just t.fill to
> fill the resulting area. I think this should work well


Hi Edwin,

Unfortunately, you may not be happy with the results if you do a fill  
with the contours.

I've used the "industry standard" contour finding algorithm, and it  
seems to work okay for stroked contours.  But if you take a very  
close-up look at the contours you'll see that they are doing goofy  
things with lots of tiny zigs and zags and a large number of breaks,  
none of which are really necessary.  (Try printing out the number of  
gaps in a typical contour -- you'll be amazed!)

If you can suggest a better contour finding algorithm, we could give  
it a try.  But I'm afraid this is one of those problems that turns  
out to be a lot more difficult that it looks at first.

Here's the link to a description of the current routine:
http://local.wasp.uwa.edu.au/~pbourke/papers/conrec/

--Bill

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://rubyforge.org/pipermail/tioga-users/attachments/20061212/ce43daa2/attachment.html 


More information about the Tioga-users mailing list