[postgis-devel] WKTRaster & overviews

Martin Daly Martin.Daly at cadcorp.com
Wed May 13 04:48:37 PDT 2009


Frank's raster_columns metadata table is more-or-less implemented now,
so I'd like to propose a further development.

If the raster_columns "regular_blocking" value is true then "all blocks
are equal sized, abutted and non-overlapping, started at top left
origin", plus additional constraints.

This regular blocking capability raises the possibility of having very
large contiguous raster coverages (made up of many individual
WKTRaster-s) which, in turn, raises potential performance problems.
Other raster formats counter this by having overviews; a concept that is
already handled by GDAL.

I would therefore like to propose an additional metadata table,
raster_overviews, as follows:

o_table_catalog
o_table_schema
o_table_name
o_column - together define the column containing overview data
r_table_catalog
r_table_schema
r_table_name
r_column - together define the base raster coverage
out_db - false if the overview uses internal tiles, true if the overview
tiles are references to files outside the database
overview_factor - the integral factor of the overview, e.g. 2 means an
overview is 1/2 resolution of the base raster coverage

Restrictions are as follows:

blocksize_x|y for the overview is the same as that of the original, base
raster coverage
pixelsize_x|y for the overview is calculated from the original, base
raster coverage pixelsize_x|y (using overview_factor)
overviews should not be registered in raster_columns
the raster_overviews table can have more than one entry for any given
base raster coverage, but they must all have different overview_factor
values, e.g. 2, 4, 8, 16, etc.

No provision is provided, or suggested, for creating, updating, or
deleting overviews. Mateusz will, however, change gdal2wktraster to
create overview tables and populate the raster_overviews table (using
GDAL-provided overviews) where relevant.

Comments welcome.

M



More information about the postgis-devel mailing list