### cpAreaForPoly() and cpPolyShape windings don't agree

Posted:

**Fri Apr 01, 2011 11:45 am**I ran into this problem recently and thought I'd mention it here. According to the documentation, the vertex winding for a cpPolyShape should be clockwise. However, calculating the area for the same set of vertices using cpAreaForPoly() returns a negative number. You'd think if the vertices were listed in the correct order, the calculated area would be positive.

As a side question, why is the winding CW? Most other physics/collision engines are CCW since the cross-product of adjacent vertex vectors is non-negative. Just wondering...

Jeff

As a side question, why is the winding CW? Most other physics/collision engines are CCW since the cross-product of adjacent vertex vectors is non-negative. Just wondering...

Jeff