Opened 17 years ago

Closed 17 years ago

#44 closed defect (fixed)

Measure tool return incorrect distance for MapServer

Reported by: aboudreault Owned by: assefa
Priority: P2 Milestone:
Component: MapServer Version: 1.0.4
Severity: Major Keywords:
Cc: yassefa@… Browser: All
External ID: Operating System: All
state: New

Description

I'm using the trunk at the moment, and the Measure.php still return incorrect distance every time. For my demo, i use gmap-ms46 data. Here the response from the php script: {distance:-1}. Ask me if you need more information.

Change History (5)

comment:1 by aboudreault, 17 years ago

Cc: yassefa@… added
Keywords: yassefa@dmsolutions.ca removed

comment:2 by assefa, 17 years ago

maybe a couple of things

  • what is the units in the map file
  • do you have mapserver build with geos ? (i yes what version) (see function msGEOSLength in mapgeos.c). If this is related to geos, we will update the bug so that there is a fall back in case geos is not defined

comment:3 by aboudreault, 17 years ago

  • the units in the map file are meters
  • The problem was effectively related to geos. My MapServer wasnt built with it. In the MapServer/php/Measure.php file, we use the method of ShapeObj class getLength and this method is only available if php/mapscript is built with GEOS library.
    $distance = $shapeObj->getLength($shapeObj);
    

comment:4 by assefa, 17 years ago

Owner: changed from madair to assefa
Status: newassigned

Remove geos dependency. Commited in 1.0.x r1350 Committed in trunk r1349

Alan, please close bug after test. Thanks.

comment:5 by aboudreault, 17 years ago

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.