Path: utzoo!utgpu!news-server.csri.toronto.edu!csri.toronto.edu!corkum Newsgroups: comp.graphics From: corkum@csri.toronto.edu (Brent Thomas Corkum) Subject: Re: Point in Polygon Problem Message-ID: <1990Aug23.181401.2258@jarvis.csri.toronto.edu> Organization: Civil Engineering, University of Toronto References: <5990@milton.u.washington.edu> <1990Aug22.022743.4139@twinsun.com> <2018@idunno.Princeton.EDU> <1990Aug23.000651.10581@twinsun.com> <2034@idunno.Princeton.EDU> <1990Aug23.174650.3592@odin.corp.sgi.com> Distribution: comp.graphics Date: 23 Aug 90 22:14:02 GMT Lines: 21 There's one question I have concerning this algorithm that I hope someone can answer. It seems to me that a point exactly on an edge can evaluate either inside or outside depending on which edge your on. ie. +----A----+ | | | | +----B----+ Using the algorithm I've seen, A would evaluate inside and B outside. Is there a quick and dirty way to handle points exactly on edges? I realize that a seperate calculation can be done to determine whether a point is on a line but this is expensive computationally isn't it? Brent corkum@ecf.toronto.edu