ProjectionObject Conversion Problem
Tom Melhuish
tmelhuish at WEBINSIGHTSINC.COM
Thu Feb 7 07:56:10 PST 2008
MS_Users,
I'm converting my mapscript code from cgi to php. I was using the following
proj4 commands in cgi to convert from Latitude / Longitude in Radians to
meters:
$pj = proj::pj_init($ProjParnNum, \@LatLongProjParm) ;
$in = new projUV();
$in->{v} = $LatRad;
$in->{u} = $LngRad;
$out = proj::pj_fwd($in, $pj);
Attached is the php code I wrote to try to perform the same conversion using
Mapserver ProjectionObject but the results are not the same. I'm not an
expert at Proj4/Projections so any help would be appreciated.
Mapserver 4.10.1
PHP 5.1.6
/** Results should be
* [x] => 668830 meters
* [x] => 177066 meters
* but are
* [x] => 45386984.852019
* [y] => -10739937.18402
*/
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ms_proj_test1.php
Type: application/octet-stream
Size: 1721 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20080207/4846788a/attachment.obj>
More information about the MapServer-users
mailing list