From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a9517107ce472fc7 X-Google-Attributes: gid103376,public From: Brian Rogoff Subject: Re: geometric utilities Date: 1998/06/03 Message-ID: #1/1 X-Deja-AN: 359283656 References: <6l2lrq$2ck$1@nnrp1.dejanews.com> Content-Type: TEXT/PLAIN; charset=US-ASCII X-Trace: 896911701 22682 bpr 206.184.139.132 Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 1998-06-03T00:00:00+00:00 List-Id: On Wed, 3 Jun 1998 mikeg2@my-dejanews.com wrote: > I'm trying to find some public domain Ada utilities > for some relatively common geometric problems - e.g., > polygon area, polygon hull, point in polygon (in > particular), and polygon tesselation (I think that's > the spelling). I've checked around in PAL and at the > AdaHome site, and not found anything. Have been > trying to implement this with the aid of various > algorithms books, and, in fact, have pretty much > everything working - except point in polygon, which > doesn't keep the tesselation routine from working, > just keeps it from generating optimal solutions (i.e., > fewest number of convex polygon partitions for a > non-convex polygon). Post your current solution, and someone will fix it. That's the beauty of the net :-). Are you trying to implement Point_In_Polygon for non-convex or convex polygons? If non-convex, I assume you are using a ray crossing technique, and not winding number calculations which are slower, right? Floating point or integer coordinates? I've implemented lots of geometric routines in C and C++ but not Ada. It should be just the same. > BTW, I have some C, C++, and Fortran versions - but > something just isn't coming out right in the translation > to Ada - the tricky part for point in polygon has to > do with edge vertices, and that's what's not working > for me. If you post a clear description of what you want, I'll try to help. Your post does bring up one of the problems of using Ada right now, that is the lack of available source libraries in an easy to find form. -- Brian