[Gdal-dev] PROJ.4 warping string ignored

Mateusz Loskot mateusz at loskot.net
Tue Oct 23 11:18:33 EDT 2007


Seth Price wrote:
> Thanks for the response. Although I don't claim to know what I'm doing,
> I'm trying to define a sphere (not the normal ellipsoid).

Seth,

Ah, right. I've missed the b semi-axis parameter.

> I'm copying
> the instructions from this page, the PROJ.4 parameters are at the bottom
> in the 'Update 4' text:
> http://cfis.savagexi.com/articles/2006/05/03/google-maps-deconstructed
> 
> Also, it doesn't make sense that I'm defining the same parameters,
> because if I directly use the proj utility, the output is different:
> 
> proj +proj=merc +datum=WGS84 +units=m -r << EOF
> ? 46 -90
> ? EOF
> -10018754.17    5749599.55
> 
> proj +proj=merc +latts=0 +lon0=0 +k=1.0 +x0=0 +y0=0 +a=6378137.0
> +b=6378137.0 +units=m -r << EOF
> ? 46 -90
> ? EOF
> -10018754.17    5780349.22
> 
> I think that gdalwarp is confusing the two commands because the image is
> shifted the same amount as the difference of these two coordinates.

Yes, your assumptions seem to be correct.

I've checked the code, and construction of spatial reference system
object (OGRSpatialReference class) ignores your a and b parameters,
recognizes proj=merc name and uses default ellipsoid.
IOW, according to my understanding, handling custom PROJ.4 definition
that uses standard projection name is not supported.

Let's wait for Frank's comment.

Cheers
-- 
Mateusz Loskot
http://mateusz.loskot.net



More information about the Gdal-dev mailing list