Ticket #1293 (closed enhancement: fixed)
[raster] ST_Resize to resize raster tiles
| Reported by: | robe | Owned by: | dustymugs |
|---|---|---|---|
| Priority: | medium | Milestone: | PostGIS Future |
| Component: | raster | Version: | trunk |
| Keywords: | history | Cc: |
Description (last modified by pracine) (diff)
Bborie,
I'm ticketing what we discussed. As mentioned, it would be nice to have a resize function that provides the similar functionality to gdal_translate that can take a percentage reduction or max pixel dimensions.
e.g.
what gdal_translate:
gdal_translate -of png -outsize 25% 25% original.png final.png gdal_translate -of png -outsize 500 500 original.png final.png
Currently have to use ST_Resample for this which requires a lot more arguments, not to mention it doesn't seem to work for rasters with no srid information.
I'm envisioning the signature would look something like
ST_Resize(rast raster, width text, height text)
where width can be a numeric like '500' or can be a percentage like '50%' which is why I made it text.
This will make postgis raster useful for both GIS folks and non-GIS folks as having an easy function to resize a raster will speed up all kinds of analysis. Like I mentioned, my selfish need is that most of my raster projects do not involve objects that fit in a nice spatial reference landscape but the analysis functions we've got so far I'm finding very useful for those (e.g. image recognition, and just plotting and vectorizing non-GIS like things like anatomic parts, or construction objects)
