{
LWDEBUG(3, "lwcircstring_segmentize: points are colinear, returning curve points as line");
- for (j = i - 1 ; j <= i ; j++)
+ for (j = i - 2 ; j < i ; j++)
{
getPoint4d_p(icurve->points, j, &p4);
ptarray_append_point(ptarray, &p4, LW_TRUE);
DROP TABLE public.circularstring;
SELECT ST_AsText(st_snaptogrid(box2d('CIRCULARSTRING(220268.439465645 150415.359530563,220227.333322076 150505.561285879,220227.353105332 150406.434743975)'::geometry),0.0001));
SELECT 'npoints_is_five',ST_NumPoints(ST_GeomFromEWKT('CIRCULARSTRING(0 0,2 0, 2 1, 2 3, 4 3)'));
+
+-- See http://trac.osgeo.org/postgis/ticket/2410
+SELECT 'straight_curve',ST_AsText(ST_CurveToLine(ST_GeomFromEWKT('CIRCULARSTRING(0 0,1 0,2 0,3 0,4 0)')));
+
public.circularstring.the_geom_2d effectively removed.
POLYGON((220187.3821 150406.4347,220187.3821 150506.7171,220288.8159 150506.7171,220288.8159 150406.4347,220187.3821 150406.4347))
npoints_is_five|5
+straight_curve|LINESTRING(0 0,1 0,2 0,3 0,4 0)