Opened 12 years ago

Last modified 7 years ago

#1858 new enhancement

[raster] Raster dataset functionality

Reported by: bnordgren Owned by: pracine
Priority: medium Milestone: PostGIS Fund Me
Component: raster Version: master
Keywords: Cc:

Description

I was playing around with a means of treating a table of raster data as if each row were a "block" in gdal or a tile in Java2D/JAI. The basic addition here is a "dataset" raster having only one band, where each "pixel" is a foreign key to the actual block with all the pixel data. Most operations are then two-phase: lookup the key in the "dataset", then perform the operation on the correct "block".

For this to work the way I wrote it, the table of raster blocks must have a "serial" primary key column. Also, it will only handle regularly tiled data (but tiles can be missing).

I'm attaching preliminary code for inferring a "dataset" from a pool of blocks having a filename field, code to read/write raster blocks and code to read/write pixels using the original (in file) pixel coordinates.

For this to represent an improvement, the "dataset" raster is going to have to be persisted in a table along with certain other information (srid, num_bands, pixel_types, nodata_values, etc.). Doing this with PostGIS functions rather than requiring all connecting applications to "roll-their-own" dataset constructs may aid interoperability.

The attached code is useful to get an idea of what will need to be stored in the "dataset table" (or view). Once the table is created, functions with smaller parameter lists can be fabricated because they can just reference the information in the table.

Enjoy.

Attachments (1)

raster_dataset.sql (17.7 KB ) - added by bnordgren 12 years ago.

Download all attachments as: .zip

Change History (4)

by bnordgren, 12 years ago

Attachment: raster_dataset.sql added

comment:1 by pracine, 12 years ago

Summary: Raster dataset functionality[raster] Raster dataset functionality

comment:2 by Bborie Park, 11 years ago

Milestone: PostGIS 2.1.0PostGIS Future
Version: 2.0.xtrunk

comment:3 by robe, 7 years ago

Milestone: PostGIS FuturePostGIS Fund Me

Milestone renamed

Note: See TracTickets for help on using tickets.