551{
552 int i, end;
553 char *ptr;
557
558 double f = 1.0;
559 double dx, dy,
x,
y, accum_x, accum_y;
560
561 ptr = output;
562
564 {
566 }
567
568 if (close_ring) end = pa->
npoints;
570
571
573
574 x = round(pt->
x*f)/f;
575 y = round(pt->
y*f)/f;
576
579 ptr += sprintf(ptr,"%s %s l", sx, sy);
580
581
584
585
586 for (i=1 ; i < end ; i++)
587 {
588
589
591
592 x = round(pt->
x*f)/f;
593 y = round(pt->
y*f)/f;
596
599
600 accum_x += dx;
601 accum_y += dy;
602
603 ptr += sprintf(ptr," %s %s", sx, sy);
604 }
605
606 return (ptr-output);
607}
#define OUT_DOUBLE_BUFFER_SIZE
int lwprint_double(double d, int maxdd, char *buf, size_t bufsize)
static const POINT2D * getPoint2d_cp(const POINTARRAY *pa, uint32_t n)
Returns a POINT2D pointer into the POINTARRAY serialized_ptlist, suitable for reading from.