[Proj] proj4 api issue converting between state plane and wgs84

Mikael Rittri Mikael.Rittri at carmenta.com
Fri Jun 8 02:32:48 PDT 2012


According to http://trac.osgeo.org/proj/wiki/pj_transform ,

  "geographic locations need to be passed in radians, 
   not decimal degrees, and will be returned similarly."

I haven't heard that this differs between the APIs.  

> which gives output that looks like this: 
> 
> ... the longitude: -1.787841 
> ... the latitude: 0.667755
> 
> which definitely is not right.

Assuming these are in radians, multiplication by 180/pi gives

Longitude: -102.4357 (decimal degrees)
Latitude: 38.2595

which is in Colorado, but quite near Kansas. I think you didn't
give the projected coordinates of the test point, so I can't
see if the radians-to-degrees conversion is all that is missing. 

Best regards,

Mikael Rittri
Carmenta
Sweden
http://www.carmenta.com

-----Original Message-----
From: proj-bounces at lists.maptools.org [mailto:proj-bounces at lists.maptools.org] On Behalf Of jdb1a1
Sent: Tuesday, June 05, 2012 9:36 PM
To: proj at lists.maptools.org
Subject: Re: [Proj] proj4 api issue converting between state plane and wgs84

Well, I tested out the same code base in with a wrapper for c# in proj4 and
it works fine.  I am going to process it on the server instead.  If anybody
knows why this didn't work in the Proj4 C API, I would still love to know.

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/proj4-api-issue-converting-between-state-plane-and-wgs84-tp4979285p4979307.html
Sent from the PROJ.4 mailing list archive at Nabble.com.
_______________________________________________
Proj mailing list
Proj at lists.maptools.org
http://lists.maptools.org/mailman/listinfo/proj



More information about the Proj mailing list