[Mapserver-users] Reprojection of shape file.

Pericles Nacionales nacional at cbs.umn.edu
Thu Feb 5 15:16:04 PST 2004


Jason,

It seems to me that the projection parameters you're passing are not quite
right.  You need to also pass lat_0, lon_0, lon_1, and the x and y
shifts--that should all be part of your stateplane coordinate system.
Check the epsg file, for your particular cs.  Or google it for more info.

One other thing, be consistent with your datum--NAD83 isn't WGS84.  I
realize there might not be that big of a difference but it might matter to
you.

-Perry

On Thu, 5 Feb 2004, Jason M. Nielsen wrote:

> Quoting Pericles Nacionales <nacional at cbs.umn.edu>:
>
> >
> > Why don't you run ogrinfo on your data and see if the extents are actually
> > in latlong?  Or if the shapefiles include a .PRJ extension, open it up and
> > see what the projection is.  If they are in latlong, run cs2cs to
> > reproject the extents to the stateplane cs.
>
> Its definitely in latlong wgs84 according to the file but I questioned wether
> the proper coordinate system was assigned for the data. Below I have listed out
> what I know of the file and my results from other commands. I was unaware of the
> existence of "cs2cs". Nice utility to have.
>
> Based on what I can tell something is goofy. Those coordinates output from cs2cs
> are nowhere near data I know to be good. Again, looks like I am doing something
> wrong or the data is munged.
>
> Could the coordinates in the shape file listed below be the reason for the ERROR
> 1 I experienced before with ogr2ogr?
>
> [root at vad3rZIM data]# cs2cs +proj=latlong +datum=NAD83 +to +proj=lcc
> +datum=NAD83 -r EOF
> Rel. 4.4.7, 31 March 2003
> <cs2cs>:
> Sys errno: 2: <system mess. texts unavail.>
> EOF
> [root at vad3rZIM data]# cs2cs +proj=latlong +datum=NAD83 +to +proj=lcc +datum=NAD83 -r
> 40.430850 111.779615
> 7230060.25      9889135.69 0.00
> 40.845718 112.121004
> 7196382.84      9931470.40 0.00
>
> [root at vad3rZIM data]# ogrinfo -al slc2002photos.shp | more
> INFO: Open of `slc2002photos.shp'
> using driver `ESRI Shapefile' successful.
>
> Layer name: slc2002photos
> Geometry: Polygon
> Feature Count: 392
> Extent: (40.430850, 111.779615) - (40.845718, 112.121004)
> Layer SRS WKT:
> GEOGCS["GCS_WGS_1984",
>     DATUM["WGS_1984",
>         SPHEROID["WGS_1984",6378137.0,298.257223563]],
>     PRIMEM["Greenwich",0.0],
>     UNIT["Degree",0.0174532925199433]]
>
>
> -------------------------------------------------
> This mail sent through IMP: http://horde.org/imp/
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>



More information about the MapServer-users mailing list