[GRASS-dev] GAL Framework and GRASS rasters
Glynn Clements
glynn at gclements.plus.com
Sun Oct 28 23:36:29 EDT 2007
Radek Bartoň wrote:
> > The row argument passed to G_get_raster_row() is converted from the
> > region's grid to the raster's grid (by compute_window_row in
> > get_row.c) to determine which row to read from the file.
> >
> > If the region resolution is coarser than the map's resolution, a
> > contiguous sequence of region rows will result in a discontiguous
> > sequences of raster rows.
>
> So some further computation over high-detailed data is needed.
>
> Are the number of columns in returned row at finest resolution or at coarse?
Coarse. All raster data provided to modules conforms to the region
used by the module. This ensures consistency when reading multiple
raster maps with different grids. Unless explicitly set by the module,
the region is set automatically from $GRASS_REGION, the file specified
by $WIND_OVERRIDE, or the WIND file.
Most modules neither know nor care about the original grid of a raster
map. The main exceptions are the various r.resamp.* modules, which
specifically read the raster at its native resolution.
> Are rows from finer resolution that are not in coarse resolution just skipped
> away or are there possibilities to apply for example low-pass filter or
> reclassification during rescale?
No, they're just skipped.
The automatic resampling is limited to nearest-neighbour resampling.
If you want anything else, you need to explicitly resample the map
with one of the r.resamp.* modules.
--
Glynn Clements <glynn at gclements.plus.com>
More information about the grass-dev
mailing list