[postgis-tickets] [SCM] PostGIS branch master updated. 3.4.0rc1-348-g71d841f45

git at osgeo.org git at osgeo.org
Thu Sep 7 18:02:49 PDT 2023


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "PostGIS".

The branch, master has been updated
       via  71d841f45119ce598865d502a1ed5a642b025cc5 (commit)
      from  5aea68f0f785d06e280740bba208d0503f24a744 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 71d841f45119ce598865d502a1ed5a642b025cc5
Author: Paul Ramsey <pramsey at cleverelephant.ca>
Date:   Thu Sep 7 13:32:32 2023 -0700

    Include min elevation when in polygonize mode for ST_Contour

diff --git a/raster/rt_core/rt_gdal.c b/raster/rt_core/rt_gdal.c
index 1d12d7dcc..95038b256 100644
--- a/raster/rt_core/rt_gdal.c
+++ b/raster/rt_core/rt_gdal.c
@@ -136,6 +136,7 @@ int rt_raster_gdal_contour(
 	/* For building out options list */
 	stringbuffer_t sb;
 	char **papszOptList = NULL;
+	const char* elev_field = polygonize ? "ELEV_FIELD_MIN" : "ELEV_FIELD";
 
 	_rti_contour_arg arg;
 	_rti_contour_arg_init(&arg);
@@ -223,7 +224,8 @@ int rt_raster_gdal_contour(
 	}
 
 	stringbuffer_aprintf(&sb, "ID_FIELD=%d ", 0);
-	stringbuffer_aprintf(&sb, "ELEV_FIELD=%d ", 1);
+	stringbuffer_aprintf(&sb, "%s=%d ", elev_field, 1);
+
 	stringbuffer_aprintf(&sb, "POLYGONIZE=%s ", polygonize ? "YES" : "NO");
 
 	papszOptList = CSLTokenizeString(stringbuffer_getstring(&sb));

-----------------------------------------------------------------------

Summary of changes:
 raster/rt_core/rt_gdal.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
PostGIS


More information about the postgis-tickets mailing list