[GRASS-dev] WinGRASS: r.in.gdal projection issue

Glynn Clements glynn at gclements.plus.com
Sun May 11 01:12:25 EDT 2008


marco.pasetti at alice.it wrote:

> During WinGRASS 6.3.0 testings I encontered a problem with the r.in.gdal
> module: it reports no errors, and correctly import rasters, but fails
> creating the projection for the new location created during raster
> import.
> I explain better with an example: I imported an SRTM tile, to be
> imported in a new location named "test", with the following command
> line:
>  
> r.in.gdal {input=C:/Documents and Settings/Marco/Documenti/GIS Data
> Repository/SRTM v3.0 DEM 90m/Z_39_3.ASC} output=Z_39_3.dem
> location=test
> 
> At the end of the Run it reports as follows in the output window:
> 
> Location <test> created
> 
> r.in.gdal complete.
> 
> After that I exit GRASS and I restart it accessing the location test:
> the raster have been correctly imported, the region set to the raster
> boundaries, but if type:
> 
> g.proj -j
> 
> it reports
> 
> XY (unprojected)
> 
> talking in IRC with a linux huy, I asked him to do the same command
> using the same raster with GRASS-6.3.0SVN: the location test, for him,
> has a correct projection (that is latlong wgs84 and so on...). So I
> guess that is a windows problem, but I don't really know why since the
> command doesn't report errors!
> 
> any suggestions?

Check the existence and contents of the following:

	<database>/test/
	<database>/test/PERMANENT/
	<database>/test/PERMANENT/DEFAULT_WIND
	<database>/test/PERMANENT/PROJ_INFO
	<database>/test/PERMANENT/PROJ_UNITS

where <database> is the GRASS database directory.

In particular, check whether the files have Unix (LF) or DOS (CR+LF)
line endings (if the files look correct in Notepad, they have DOS line
endings; with Unix line endings, you get one long line with little
black blocks).

-- 
Glynn Clements <glynn at gclements.plus.com>


More information about the grass-dev mailing list