[prev in list] [next in list] [prev in thread] [next in thread] 

List:       postgis-users
Subject:    Re: [postgis-users] Which operators/functions work with circular arcs?
From:       Paul Ramsey <pramsey () cleverelephant ! ca>
Date:       2015-08-22 22:35:04
Message-ID: CACowWR3bB374mJtFRG8z-m39KJd5+_qpGxE6y5fu8EN7wDQHMA () mail ! gmail ! com
[Download RAW message or body]

I was about to point out how clever I was, to work this out and then
forget I'd worked it out, but then I found this,

double
lwcurvepoly_area(const LWCURVEPOLY *curvepoly)
{
double area = 0.0;
LWPOLY *poly;
if( lwgeom_is_empty((LWGEOM*)curvepoly) )
return 0.0;
poly = lwcurvepoly_stroke(curvepoly, 32);
area = lwpoly_area(poly);
lwpoly_free(poly);
return area;
}

On Fri, Aug 21, 2015 at 5:29 PM, Paragon Corporation <lr@pcorp.us> wrote:
> Paul,
>
>> The area calculations don't work.
>
>> A comprehensive survey would be most appreciated.
>
> By they don't work, what exactly do you mean? Do you mean it gives the wrong
> answer?
>
> The gardens tests on curves didn't error out on ST_Area.  This same test
> also doesn't error out in PostGIS 2.1
>
> SELECT ST_Area(
> ST_GeomFromEWKT('SRID=4326;CURVEPOLYGON(CIRCULARSTRING(-71.0821 42.3036,
> -71.4821 42.3036, -71.7821 42.7036, -71.0821 42.7036, -71.0821
> 42.3036),(-71.1821 42.4036, -71.3821 42.6036, -71.3821 42.4036, -71.1821
> 42.4036) ) ') );
>
> Thanks,
> Regina
> On Thu, Aug 20, 2015 at 7:30 AM, Andreas Neumann <a.neumann@carto.net>
> wrote:
>> Hi,
>>
>> I wonder how I can find out what operators and what functions work
>> with circular arcs? Are they marked in the documentation as such?
>>
>> Thank you for your hints!
>>
>> Andreas
>> _______________________________________________
>> postgis-users mailing list
>> postgis-users@lists.osgeo.org
>> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
> _______________________________________________
> postgis-users mailing list
> postgis-users@lists.osgeo.org
> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users@lists.osgeo.org
> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
_______________________________________________
postgis-users mailing list
postgis-users@lists.osgeo.org
http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic