853 lwerror(
"ptarrayarc_contains_point called with even number of points");
860 lwerror(
"ptarrayarc_contains_point called too-short pointarray");
867 if ( check_closed && !
p2d_same(seg1, seg3) )
869 lwerror(
"ptarrayarc_contains_point called on unclosed ring");
888 else if ( d < radius )
900 for ( i=1; i < pa->
npoints; i += 2 )
925 if ( (pt->
x > gbox.
xmax || pt->
x < gbox.
xmin) &&
935 if ( (side == 0) &&
lw_pt_in_arc(pt, seg1, seg2, seg3) )
941 if ( side < 0 && (seg1->
y <= pt->
y) && (pt->
y < seg3->
y) )
947 if ( side > 0 && (seg2->
y <= pt->
y) && (pt->
y < seg1->
y) )
953 if ( pt->
x <= gbox.
xmax && pt->
x >= gbox.
xmin )
979 if ( winding_number )
980 *winding_number = wn;
double lw_arc_center(const POINT2D *p1, const POINT2D *p2, const POINT2D *p3, POINT2D *result)
Determines the center of the circle defined by the three given points.
int lw_arc_is_pt(const POINT2D *A1, const POINT2D *A2, const POINT2D *A3)
Returns true if arc A is actually a point (all vertices are the same) .
int lw_arc_calculate_gbox_cartesian_2d(const POINT2D *A1, const POINT2D *A2, const POINT2D *A3, GBOX *gbox)
double distance2d_pt_pt(const POINT2D *p1, const POINT2D *p2)
The old function nessecary for ptarray_segmentize2d in ptarray.c.
int p2d_same(const POINT2D *p1, const POINT2D *p2)
const POINT2D * getPoint2d_cp(const POINTARRAY *pa, int n)
Returns a POINT2D pointer into the POINTARRAY serialized_ptlist, suitable for reading from...
#define LW_INSIDE
Constants for point-in-polygon return values.
int lw_arc_side(const POINT2D *A1, const POINT2D *A2, const POINT2D *A3, const POINT2D *Q)
int lw_pt_in_arc(const POINT2D *P, const POINT2D *A1, const POINT2D *A2, const POINT2D *A3)
Returns true if P is on the same side of the plane partition defined by A1/A3 as A2 is...
void lwerror(const char *fmt,...)
Write a notice out to the error handler.