shawnlaffan / Geo-ShapeFile

A perl library for reading shapefiles
https://metacpan.org/module/Geo::ShapeFile
2 stars 1 forks source link

optimise shapes_in_area #9

Closed shawnlaffan closed 10 years ago

shawnlaffan commented 10 years ago

From Daniel Smith via RT #89563:

A working algorithm only needs one line as follows:

return !($x1_min > $x2_max or $x1_max < $x2_min or $y1_min > $y2_max or $y1_max < $y2_min);