R/chipmunk.R
cpAreaForPoly.RdCalculate the signed area of a polygon. A Clockwise winding gives positive area. This is probably backwards from what you expect, but matches Chipmunk's the winding for poly shapes.
cpAreaForPoly(count, verts, radius)
| count | [ |
|---|---|
| verts | [ |
| radius | [ |
[cpFloat]
C function prototype: CP_EXPORT cpFloat cpAreaForPoly(const int count, const cpVect *verts, cpFloat radius);