Just a quick comment here: The r.in.gdal provides a
flag "-e" with the required code to enlarge the
DEFAULT_WIND. Maybe we simply move this code portion
to libgis and use it also for g.region?
It's almost done, I think.
Markus
Just a quick comment here: The r.in.gdal provides a
flag "-e" with the required code to enlarge the
DEFAULT_WIND. Maybe we simply move this code portion
to libgis and use it also for g.region?
It's almost done, I think.
Markus
Markus Neteler wrote:
Just a quick comment here: The r.in.gdal provides a
flag "-e" with the required code to enlarge the
DEFAULT_WIND. Maybe we simply move this code portion
to libgis and use it also for g.region?
The way in which r.in.gdal does it is a hack:
G__put_window( &def_wind, "../PERMANENT", "DEFAULT_WIND" );
Actually, G__put_window itself is something of a hack, as it
encourages individual modules to contain hardcoded assumptions about
the directory structure.
I suggest that a more correct way to do it would be to temporarily
switch the mapset to PERMANENT, then use:
G__put_window (window,"", "DEFAULT_WIND");
Also, it's arguable that r.in.gdal should be modifying the per-mapset
window rather than the default window; a normal user may not have the
necessary permissions to modify anything in PERMANENT.
--
Glynn Clements <glynn.clements@virgin.net>