We have some raster image data stored as GeoTIFF which we would like to make available online as an overlay using the OpenGeo framework. As the data covers only a spatially restricted area and we don't need too much zoom levels, we consider precomputing ("seeding") the tiles as applicable with respect to memory consumption. Using OpenGeo, there seem to be two modules which can handle tiling:

raster2pgsql: a command line tool which converts a raster file into a series of SQL commands that can be loaded into postGIS. It offers the option to specify the tile size and the zoom levels (in their syntax "overviews")

GeoWebCache: assists GeoWebServer with cache functionality and tile generation. The latter can be done prior to client requests or on the fly.

I'm not sure about how the two differ with respect to the precomputed tiles, can anybody clarify this? At first glance I tend to GeoWebCache because of the convenient access through its web interface.

1 Answer
1

GWC and raster2pgsql do quite different things. They both use image tiles, but use them to do very different things.

raster2pgsql is a way to store a large raster data sets inside Postgres. The tiles are an implementation detail used to allow for faster lookup of subsets of the raster and have no impact on what's served up by GeoServer in a WMS or WCS. It's purely a back end, datastore thing.

GeoWebCache sits on the client facing side of GeoServer, caches the styled map images produced by a WMS as tiles, and presents those tiles as a WMS in turn (Or using one of the other tile protocols is supports) This saves you the overhead of reading and interpreting the data from storage, styling the data, scaling and projecting it, and encoding it as an image and instead simply sends a stored image from disk.