[ gpsdrive ] Nautical maps
Hamish
hamish_b at yahoo.com
Sat Mar 8 18:07:51 AKST 2008
tartifola wrote:
> > what does 'g.proj -p' say?
>
> XY location (unprojected)
....
> > what is the complaint it gives you? (exact cut & paste is best)
>
> <PROJ_INFO> file not found for location <Palma di Maiorca>
> <PROJ_UNITS> file not found for location <Palma di Maiorca>
simple XY locations are without map projection.
I am not sure, but spaces in location and mapset names could be
problematic. I usually use underscores. On the other side someone has
to try to find if there are any parts of the code which doesn't quote
names properly. :)
> Driver <GIF> does not support direct writing. Using MEM driver for
> intermediate dataset.
GIF sucks (256 color limit), use PNG instead.
> Exporting to GDAL data type: Byte
> Unable to set projection
Again, simple XY space is without projection. Map coordinates are given
in image pixels.
> I'm sorry for the late reply but I've been very busy. I did some step
> forward but still I have the feeling to be somehow lost :-) Now I'm
> able to generate a .gif file but I do not know how to have gpsdrive
> to put the map in the correct place. I quick summary of my steps.
don't use r.out.gdal to create gpsdrive tiles. Use d.out.gpsdrive
instead.
> 1. I've got two files M0011.BSB and M0011_1.KAP
[BSB raster image charts (aka scans of paper charts)]
then the easiest way is to not use GRASS but to use gdalwarp to
georectify the image into a geo-referenced GeoTiff using the ground
control points embedded in the data, then running gdal_slice.sh to cut
it up into gpsdrive tiles. As detailed here:
http://article.gmane.org/gmane.comp.linux.gps/3937/
that method is quite simple.
For S-57 vector data you will want to use GRASS as you pick from the
many data layers, set colors, etc.. More about that in the next email.
> 2. I generate a new region with grass63 using the georeference option
> and using the .KAP file
the BSB raster chart's .KAP file is an unregistered image which
contains some metadata which has a table of pixel 123,456 is xx.xxxx
long, yy.yyyy lat. So it creates a XY location with GCPs saved to the
image group's POINTS file. Create a lat/lon WGS84 location and in the
XY location set i.target to that. Then run 'i.rectify order=2' to
convert to a georeferenced map in the lat/lon location. (this is the
same process as gdalwarp). Finally, run d.out.gpsdrive from the lat/lon
location.
> 3. I import a new raster map using again the file .KAP and obtaining
> on OK from grass63. Here the log
>
> Projection of input dataset and current location appear to match
>
> Copying 8 GCPS in points file for <porto>
> GCPs have the following OpenGIS WKT Coordinate System::
> GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS
84",6378137,298.257223563,AUTHORITY["EPSG",7030]],TOWGS84[0,0,0,0,0,0,0],AUTHORITY["EPSG",6326]],PRIMEM["Greenwich",0,AUTHORITY["EPSG",8901]],UNIT["degree",0.0174532925199433,AUTHORITY["EPSG",9108]],AXIS["Lat",NORTH],AXIS["Long",EAST],AUTHORITY["EPSG",4326]]
>
> r.in.gdal complete.
this is the "ground control point" pixel<->map coordinate info needed
for i.rectify.
> 4. I modify my map: scale, color, etc...
>
> 5. I try to export a raster map with the command
>
> r.out.gdal input=porto.palette at PERMANENT format=GIF
> output=~/pippo.gif
>
> obtaining the complain above reported but obtaing a "non empty" file
again, d.out.gpsdrive not r.out.gdal for gpsdrive tiles.
Hamish
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
More information about the GPSdrive
mailing list