Getting ready

In this recipe, we will convert rasters to geometries, and geometries to rasters. We will use the ST_DumpAsPolygons() and ST_PixelsAsPolygons() functions to convert rasters to geometries. We will then convert geometries to rasters using ST_AsRaster().

Get PostGIS Cookbook - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.