[GRASS5] [bug #1047] (grass) suggestion to solve r.proj initialization problem

this bug's URL: http://intevation.de/rt/webrt?serial_num=1047
-------------------------------------------------------------------------

Subject: suggestion to solve r.proj initialization problem

grass binary for platform: Compiled from Sources

It appears that r.in.gdal sometimes (e.g. ASTERDEM/GTIFF) write a PROJ_INFO file with upper-case ellipsoid. This is not accepted by [rvs].proj:

r.proj in=asterdem loc=mainz map=PERMANENT out=mainz.asterdem res=30
cannot initialize pj
cause: unknown elliptical parameter name
ERROR: Can't get projection key values of input mapG

PROJ_INFO looks as follows:
projection: 1 (UTM)
zone: 32
datum: WGS84
ellipsoid: WGS84
[...]

When changing datum/ellips to lower case characters, it works (of course).

My suggestion is to apply the function
char * G_tolcase (string)

somewhere in
key_value2.c called by
src/libes/gis/get_projinfo.c

to generally resolve that problem.

Markus

PS: reported by Otto Dassau

-------------------------------------------- Managed by Request Tracker

My suggestion is to apply the function
char * G_tolcase (string)

somewhere in
key_value2.c called by
src/libes/gis/get_projinfo.c

to generally resolve that problem.

Markus

This is a special case where the GRASS ellipsoid name differs from proj's
ellipsoid name _only_ by case. There are other cases where the names are
completely different. Would not a long-term solution better have common
list of ellipsoid names?

Morten Hulden