Alex Perry writes: > >Can we patch the sgdPointInTriangle back to PointInTriangle >_and_ keep the improvements from Norman in the tree ?
Alex I believe all of my improvements are in the tree. Although I have yet to add the IntersectCachedLeaf() routine which can give yet another order of magnitude (or two) of speedup with out much penalty for misses for most cases where one is doing multiple queries in close proxsition. FWIW I believe the sgdPointInTriangle() is currently faster for our use then the commented out 'testbed' PointInTriangle() that I 'inadvertenly' left in the code, in that it often takes the early out faster :-) < a bounding box test though ugly to see in code is hard to beat > FYI the sgdPointinTriangle() was specifically written for use with these FGFS routines and was moved to PLib so others could take advantage of it recently. However, as you observed, my test routine is 'elegant' and 'quite' fast it was gleaned from a recent discussion on the games-algorithms list and is very close to what was being advocated there as an 'optimium' solution and IMHO deserves study until understood :-) Cheers Norman _______________________________________________ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
