[GRASS-dev] [GRASS GIS] #2428: r.external to accept gdal config options
GRASS GIS
trac at osgeo.org
Fri Sep 26 02:27:01 PDT 2014
#2428: r.external to accept gdal config options
-------------------------+--------------------------------------------------
Reporter: perrygeo | Owner: grass-dev@…
Type: enhancement | Status: new
Priority: normal | Milestone: 7.1.0
Component: Default | Version: svn-trunk
Keywords: r.external | Platform: Unspecified
Cpu: x86-64 |
-------------------------+--------------------------------------------------
Comment(by neteler):
Replying to [comment:2 glynn]:
> Replying to [comment:1 neteler]:
> > The request sounds reasonable but I didn't figure out how to pass
"papszOptions" to GDAL as used in r.external. The magic line in r.out.gdal
is this:
>
> > but in r.external GDALOpen() is used. Perhaps a GDAL expert can tell
us the trick.
>
> Note that r.external is the analogue of r.in.gdal, which doesn't accept
any configuration options.
While it doesn't directly, I had added a larger cache some time ago by
setting GDALSetCacheMax() to 300MB rather than the tiny 40MB default GDAL
cache size. This speeds up import tremendously:
{{{
r.in.gdal ...
memory=integer
Maximum memory to be used (in MB)
Cache size for raster rows
Options: 0-2047
Default: 300
}}}
I wonder how to get that into r.external (I suppose that it would benefit
as well).
> If options are needed for reading, a similar option should be added to
both r.in.gdal and r.external, presumably using GDALOpenEx() instead of
GDALOpen(). The latter will require extending the GDAL "link" format
(lib/raster/gdal.c).
OK (no idea how to implement that).
--
Ticket URL: <http://trac.osgeo.org/grass/ticket/2428#comment:3>
GRASS GIS <http://grass.osgeo.org>
More information about the grass-dev
mailing list