Just another Perl shrine | |
PerlMonks |
Re: Speeding up point-in-polygon -- take twoby hardburn (Abbot) |
on Aug 28, 2006 at 15:04 UTC ( [id://569993]=note: print w/replies, xml ) | Need Help?? |
Using a bounding box is a good start, but a bounding circle should be even better. A circle only needs to test one dimention:
I've also found that dropping some of the calculations into C can speed it up quite a bit without being terribly complex to interface back to Perl. "There is no shame in being self-taught, only in not trying to learn in the first place." -- Atrus, Myst: The Book of D'ni.
In Section
Seekers of Perl Wisdom
|
|