From 79d3ee46545f1a5b60d40bfe8a803974a97d0a09 Mon Sep 17 00:00:00 2001 From: Richard Fairhurst Date: Fri, 13 Feb 2009 15:12:52 +0000 Subject: [PATCH] be a bit smarter about enlarging the bbox (note to self: must remember to put this in 0.6 too) --- app/controllers/amf_controller.rb | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/app/controllers/amf_controller.rb b/app/controllers/amf_controller.rb index 2b21221c0..febc4db68 100644 --- a/app/controllers/amf_controller.rb +++ b/app/controllers/amf_controller.rb @@ -126,8 +126,9 @@ class AmfController < ApplicationController # are IDs only. def whichways(xmin, ymin, xmax, ymax) #:doc: - xmin -= 0.01; ymin -= 0.01 - xmax += 0.01; ymax += 0.01 + enlarge = [(xmax-xmin)/8,0.01].min + xmin -= enlarge; ymin -= enlarge + xmax += enlarge; ymax += enlarge if POTLATCH_USE_SQL then way_ids = sql_find_way_ids_in_area(xmin, ymin, xmax, ymax) -- 2.43.2