[geos-devel] Optimized Geometry/Rectangle Intersection status (#699)

Sandro Santilli strk at keybit.net
Tue Sep 9 03:18:44 PDT 2014


FYI, Mika sent me his code and I've completed its porting to GEOS.
At the moment all provided tests (142 cases) pass and valgrind reports
no memory error (apart some small leaks).

If anyone wants to take a look the code can be found here:

 https://github.com/strk/libgeos/tree/svn-trunk-fast-rect-intersection

Here are the tests:

 https://github.com/strk/libgeos/blob/svn-trunk-fast-rect-intersection/tests/unit/operation/intersection/RectangleIntersectionTest.cpp

Next I'll plug the memory leaks and then start looking at more test cases
and performance. 

One thing I noticed is that 2.5D Coordinates are not fully supported by
this class, while they are by the standard intersection code. Making
the new code fired on standard intersection would require adding such
support.

Tests welcome !

--strk;

On Fri, Aug 29, 2014 at 04:20:11PM +0200, Sandro Santilli wrote:
> On Fri, Aug 29, 2014 at 05:17:57PM +0300, Mika Heiskanen wrote:
> > On 08/27/2014 11:09 AM, Sandro Santilli wrote:
> > >I'm very interested in your code and willing to help with integration.
> > >
> > >I guess this could be a RectangleIntersection class under a new
> > >geos::operation::intersection namespace, eventually further wrapped
> > >by a generic IntersectionOp using RectangleIntersection when an input
> > >is a rectangle or the generic OverlayOp in other cases.
> > >Then Geometry::intersection would be using that specialized class.
> > >
> > >Please let me know how I can help with this.
> > 
> > I will try to port the code to the class and namespace you mentioned.
> > There will be some helper classes too. I will also see if I can
> > integrate the tests we have with your existing system. Integration with
> > IntersectionOp etc is not what I am comfortable with, as I know too
> > little of existing GEOS code.
> 
> Don't worry about intergration with IntersectionOp, I can do that part.
> Testcases would be very important to get in.
> 
> --strk;
> 
>  ()  ASCII ribbon campaign  --  Keep it simple !
>  /\  http://strk.keybit.net/rants/ascii_mails.txt  

-- 

 ()  ASCII ribbon campaign  --  Keep it simple !
 /\  http://strk.keybit.net/rants/ascii_mails.txt  


More information about the geos-devel mailing list