[postgis-tickets] r15389 - ST_AsMVT Normalize output to make sure it will be identical regardless of GEOS version

bjorn at wololo.org bjorn at wololo.org
Thu May 4 11:40:26 PDT 2017


Author: bjornharrtell
Date: 2017-05-04 11:40:26 -0700 (Thu, 04 May 2017)
New Revision: 15389

Modified:
   trunk/postgis/mvt.c
   trunk/regress/mvt_expected
Log:
ST_AsMVT Normalize output to make sure it will be identical regardless of GEOS version
References #3749

Modified: trunk/postgis/mvt.c
===================================================================
--- trunk/postgis/mvt.c	2017-05-04 18:01:55 UTC (rev 15388)
+++ trunk/postgis/mvt.c	2017-05-04 18:40:26 UTC (rev 15389)
@@ -711,7 +711,7 @@
 	if (lwgeom_out == NULL || lwgeom_is_empty(lwgeom_out))
 		return NULL;
 
-	return lwgeom_out;
+	return lwgeom_normalize(lwgeom_out);
 }
 
 /**

Modified: trunk/regress/mvt_expected
===================================================================
--- trunk/regress/mvt_expected	2017-05-04 18:01:55 UTC (rev 15388)
+++ trunk/regress/mvt_expected	2017-05-04 18:40:26 UTC (rev 15389)
@@ -1,20 +1,20 @@
 PG1|POINT(1 4094)
 PG2|POINT(0 4095)
 PG3|POINT(2 4092)
-PG4|MULTIPOLYGON(((5 4096,10 4096,10 4091,5 4096)),((5 4096,0 4096,0 4101,5 4096)))
+PG4|MULTIPOLYGON(((5 4096,10 4096,10 4091,5 4096)),((0 4096,0 4101,5 4096,0 4096)))
 PG5|
-PG6|POLYGON((894 2704,2791 594,600 594,894 2704))
+PG6|POLYGON((600 594,894 2704,2791 594,600 594))
 PG7|POLYGON((1251 1904,1252 1905,1253 1906,1253 1905,1252 1904,1251 1904))
-PG8|MULTIPOLYGON(((5 4096,10 4096,10 4091,5 4096)),((5 4096,0 4096,0 4101,5 4096)))
-PG9|POLYGON((0 4096,4096 4096,4096 0,0 0,0 4096))
+PG8|MULTIPOLYGON(((5 4096,10 4096,10 4091,5 4096)),((0 4096,0 4101,5 4096,0 4096)))
+PG9|POLYGON((0 0,0 4096,4096 4096,4096 0,0 0))
 TG1|GiEKBHRlc3QSDBICAAAYASIECTLePxoCYzEiAigBKIAgeAI=
-TG2|GiMKBHRlc3QSDhICAAAYASIGETLePwIBGgJjMSICKAEogCB4Ag==
+TG2|GiMKBHRlc3QSDhICAAAYASIGETTcPwECGgJjMSICKAEogCB4Ag==
 TG3|GiYKBHRlc3QSERICAAAYAiIJCQCAQArQD88PGgJjMSICKAEogCB4Ag==
 TG4|GioKBHRlc3QSFRICAAAYAiINCQCAQBLoB+cH6AfnBxoCYzEiAigBKIAgeAI=
-TG5|GjgKBHRlc3QSIxICAAAYAiIbCQL+PxLoB+cH6AfnBwnND84PEugH5wfoB+cHGgJjMSICKAEogCB4
+TG5|GjgKBHRlc3QSIxICAAAYAiIbCQT8PxLoB+cH6AfnBwnRD9IPEugH5wfoB+cHGgJjMSICKAEogCB4
 Ag==
-TG6|GjIKBHRlc3QSHRICAAAYAyIVCUbsPxoURTsKCSgPCRQTEh4JCR4PGgJjMSICKAEogCB4Ag==
-TG7|Gj0KBHRlc3QSKBICAAAYAyIgCVCwPxInCTIeDwkxCSITCgAoKAoeHQ8JHQASEwoAEw8aAmMxIgIo
+TG6|GjIKBHRlc3QSHRICAAAYAyIVCRTYPxoyFBRFOwoPCQoUEh4JCR4PGgJjMSICKAEogCB4Ag==
+TG7|Gj0KBHRlc3QSKBICAAAYAyIgCRTEPyIAKCgKHh0xHQ8JABQSFAoTCg8JADsSMh4JEw8aAmMxIgIo
 ASiAIHgC
 TG8|GiEKBHRlc3QSDBICAAAYASIECTLePxoCYzEiAigBKIAgeAI=
 TG9|GiMKBHRlc3QSDhICAAAYASIGETLeP2VGGgJjMSICKAEogCB4Ag==



More information about the postgis-tickets mailing list