]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge remote-tracking branch 'upstream/master'
authorSarah Hoffmann <lonvia@denofr.de>
Thu, 28 May 2015 19:27:11 +0000 (21:27 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Thu, 28 May 2015 19:27:11 +0000 (21:27 +0200)
1  2 
lib/Geocode.php

diff --cc lib/Geocode.php
index c79dcf1ea5d41e49af50b7c0cbd4168af264c28d,4ca832dca5c9425092acc58bdfcb54f3d285f5c0..a9fe96114ad1093a68a8d84976d04ed809dea2da
                                                        {
                                                                preg_match_all('/(-?[0-9.]+) (-?[0-9.]+)/',$aMatch[1],$aPolyPoints,PREG_SET_ORDER);
                                                        }
 +                            */
                                                        elseif (preg_match('#POINT\\((-?[0-9.]+) (-?[0-9.]+)\\)#',$aPointPolygon['astext'],$aMatch))
                                                        {
-                                                               $iSteps = ($fRadius * 40000)^2;
+                                                               $iSteps = max(8, min(100, ($fRadius * 40000)^2));
                                                                $fStepSize = (2*pi())/$iSteps;
                                                                $aPolyPoints = array();
                                                                for($f = 0; $f < 2*pi(); $f += $fStepSize)