[postgis-users] Quick/unobstrusive way to determine if a geometry has curve elements?

Andrea Aime andrea.aime at geo-solutions.it
Thu May 7 03:14:29 PDT 2015


On Tue, May 5, 2015 at 6:33 PM, Andrea Aime <andrea.aime at geo-solutions.it>
wrote:

> On Tue, May 5, 2015 at 6:31 PM, Paul Ramsey <pramsey at cleverelephant.ca>
> wrote:
>
>> ST_HasArc() should do what you want
>>
>
>
Looks like there is still a wrinkle... one can build compoudcurve without
any arc in it, ST_HasArc will
return false, but ST_Simplify only check the geometry type and refuses to
work on it.
Shall I open a bug report/feature request?

Here is an example:

MULTISURFACE(CURVEPOLYGON(COMPOUNDCURVE((25496651.4916
6674112.9568,25496652.9600555 6674113.15828079,25496654.4404797
6674113.23108252,25496655.9216183 6674113.17465174,25496657.3922115
6674112.98941744,25496658.8410796 6674112.6767878,25496660.2572081
6674112.23913946,25496661.6298314 6674111.67979949,25496662.9485147
6674111.00302006,25496664.2032332 6674110.21394615,25496665.3844482
6674109.3185764,25496666.4831801 6674108.32371753,25496667.4910762
6674107.23693258,25496668.4004743 6674106.06648345,25496669.204461
6674104.82126804,25496669.8969243 6674103.51075266,25496670.4726
6674102.1449),(25496670.4726 6674102.1449,25496678.3273
6674080.9744),(25496678.3273 6674080.9744,25496709.2227
6673929.1767),(25496709.2227 6673929.1767,25496710.0592419
6673925.62354064,25496711.1103048 6673922.12782752,25496712.372
6673918.7025),(25496712.372 6673918.7025,25496714.6042041
6673913.81144642,25496717.2652786 6673909.13984902,25496720.3338569
6673904.72521794,25496723.7853 6673900.603),(25496723.7853
6673900.603,25496744.2090639 6673879.38909363,25496765.6490722
6673859.20281227,25496788.0537 6673840.0928),(25496788.0537
6673840.0928,25496801.2714 6673854.9981),(25496801.2714
6673854.9981,25496827.0266 6673832.1946),(25496827.0266
6673832.1946,25496812.5045 6673815.2716),(25496812.5045
6673815.2716,25496818.5563 6673810.0894),(25496818.5563
6673810.0894,25496854.2557 6673779.5197),(25496854.2557
6673779.5197,25496887.545 6673751.0139),(25496887.545
6673751.0139,25496890.8911 6673748.1485),(25496890.8911
6673748.1485,25496897.0822 6673743.927),(25496897.0822
6673743.927,25496902.7355681 6673740.73662356,25496908.6383069
6673738.03537638,25496914.7482 6673735.8426),(25496914.7482
6673735.8426,25496950.4171 6673727.3498),(25496950.4171
6673727.3498,25496957.9619 6673725.5533),(25496957.9619
6673725.5533,25496986.2922 6673718.5715),(25496986.2922
6673718.5715,25497010.1611 6673712.7616),(25497010.1611
6673712.7616,25497041.7216 6673705.0793),(25497041.7216
6673705.0793,25497064.5242 6673699.4726),(25497064.5242
6673699.4726,25497088.3888 6673693.6046),(25497088.3888
6673693.6046,25497096.8207 6673691.6638),(25497096.8207
6673691.6638,25497122.6558 6673690.4262),(25497122.6558
6673690.4262,25497197.1328 6673692.7781),(25497197.1328
6673692.7781,25497204.4504 6673693.0092),(25497204.4504
6673693.0092,25497224.5568 6673694.0241),(25497224.5568
6673694.0241,25497250.7102 6673695.6603),(25497250.7102
6673695.6603,25497251.0164 6673689.6954),(25497251.0164
6673689.6954,25497253.0175 6673650.7191),(25497253.0175
6673650.7191,25497256.551 6673583.7225),(25497256.551
6673583.7225,25497303.9707 6673586.4735),(25497303.9707
6673586.4735,25497301.7817 6673627.9866),(25497301.7817
6673627.9866,25497307.8107 6673628.341),(25497307.8107
6673628.341,25497331.554 6673643.0608),(25497331.554
6673643.0608,25497331.7805916 6673643.18801735,25497332.0173427
6673643.29514789,25497332.2624767 6673643.38138779,25497332.5141543
6673643.44608993,25497332.7704872 6673643.48876884,25497333.0295518
6673643.50910427,25497333.2894043 6673643.50694364,25497333.548095
6673643.48230316,25497333.8036827 6673643.43536771,25497334.0542497
6673643.36648948,25497334.2979157 6673643.27618529,25497334.5328526
6673643.16513274,25497334.7572975 6673643.0341651,25497334.9695662
6673642.88426508,25497335.1680659 6673642.71655745,25497335.3513074
6673642.53230061,25497335.5179155 6673642.3328771,25497335.6666403
6673642.11978331,25497335.7963656 6673641.89461816,25497335.9061182
6673641.65907119,25497335.9950745 6673641.41490979,25497336.0625671
6673641.16396604,25497336.1080894 6673640.90812287,25497336.1313
6673640.6493),(25497336.1313 6673640.6493,25497336.5634
6673631.288),(25497336.5634 6673631.288,25497349.9056
6673638.9515),(25497349.9056 6673638.9515,25497336.9526
6673659.042),(25497336.9526 6673659.042,25497419.119
6673710.0456),(25497419.119 6673710.0456,25497404.5574
6673733.505),(25497404.5574 6673733.505,25497407.291473
6673735.03585433,25497410.1522649 6673736.31434549,25497413.116541
6673737.33008987,25497416.1602264 6673738.07483784,25497419.2586008
6673738.54254074,25497422.3865 6673738.7294),(25497422.3865
6673738.7294,25497437.0015353 6673738.22980162,25497451.498467
6673736.30942999,25497465.7395071 6673732.98653517,25497479.5893
6673728.2927),(25497479.5893 6673728.2927,25497492.0231
6673714.1359),(25497492.0231 6673714.1359,25497496.498
6673717.6458),(25497496.498 6673717.6458,25497489.4617
6673726.2259),(25497489.4617 6673726.2259,25497497.9243436
6673724.39763888,25497506.5235036 6673723.39100026,25497515.1796
6673723.2153),(25497515.1796 6673723.2153,25497575.9995
6673724.908),(25497575.9995 6673724.908,25497552.5772
6673733.6475),(25497552.5772 6673733.6475,25497530.6426212
6673739.09828249,25497509.2643043 6673746.4334223,25497488.6038
6673755.5975),(25497488.6038 6673755.5975,25497487.4253
6673756.1826),(25497487.4253 6673756.1826,25497476.7985236
6673760.83434552,25497465.7722417 6673764.43826308,25497454.4494963
6673766.96067202,25497442.9361 6673768.378),(25497442.9361
6673768.378,25497591.0824 6673777.4071),(25497591.0824
6673777.4071,25497615.4796 6673792.432),(25497615.4796
6673792.432,25497623.4726 6673792.764),(25497623.4726
6673792.764,25497621.7848 6673826.1406),(25497621.7848
6673826.1406,25497427.9703 6673815.9988),(25497427.9703
6673815.9988,25497287.8645 6673726.6682),(25497287.8645
6673726.6682,25497245.9087 6673725.0236),(25497245.9087
6673725.0236,25497223.0902 6673724.1291),(25497223.0902
6673724.1291,25497188.8609 6673722.7873),(25497188.8609
6673722.7873,25496861.0491 6673876.1797),(25496861.0491
6673876.1797,25496865.3159 6674098.1721),(25496865.3159
6674098.1721,25496657.6795 6674114.018),(25496657.6795
6674114.018,25496652.6314 6674114.4032),(25496652.6314
6674114.4032,25496648.5035 6674114.7182),(25496648.5035
6674114.7182,25496648.9738 6674112.4987),(25496648.9738
6674112.4987,25496651.4916 6674112.9568))))

Cheers
Andrea

-- 
==
GeoServer Professional Services from the experts! Visit
http://goo.gl/NWWaa2 for more information.
==

Ing. Andrea Aime
@geowolf
Technical Lead

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272
mob: +39  339 8844549

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

*AVVERTENZE AI SENSI DEL D.Lgs. 196/2003*

Le informazioni contenute in questo messaggio di posta elettronica e/o
nel/i file/s allegato/i sono da considerarsi strettamente riservate. Il
loro utilizzo è consentito esclusivamente al destinatario del messaggio,
per le finalità indicate nel messaggio stesso. Qualora riceviate questo
messaggio senza esserne il destinatario, Vi preghiamo cortesemente di
darcene notizia via e-mail e di procedere alla distruzione del messaggio
stesso, cancellandolo dal Vostro sistema. Conservare il messaggio stesso,
divulgarlo anche in parte, distribuirlo ad altri soggetti, copiarlo, od
utilizzarlo per finalità diverse, costituisce comportamento contrario ai
principi dettati dal D.Lgs. 196/2003.



The information in this message and/or attachments, is intended solely for
the attention and use of the named addressee(s) and may be confidential or
proprietary in nature or covered by the provisions of privacy act
(Legislative Decree June, 30 2003, no.196 - Italy's New Data Protection
Code).Any use not in accord with its purpose, any disclosure, reproduction,
copying, distribution, or either dissemination, either whole or partial, is
strictly forbidden except previous formal approval of the named
addressee(s). If you are not the intended recipient, please contact
immediately the sender by telephone, fax or e-mail and delete the
information in this message that has been received in error. The sender
does not give any warranty or accept liability as the content, accuracy or
completeness of sent messages and accepts no responsibility  for changes
made after they were sent or for other risks which arise as a result of
e-mail transmission, viruses, etc.

-------------------------------------------------------
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20150507/9f609796/attachment.html>


More information about the postgis-users mailing list