Percentage of polygon intersection

156 views
Skip to first unread message

Siva ram

unread,
Feb 16, 2016, 4:44:36 AM2/16/16
to JSTS devs
Hi,

First of all thanks for creating a such useful and powerful java script library. Recently I came across one requirement based on the polygon intersection. Do JSTS library have any function to compute the percentage of polygon intersection. If not could anyone please let me know how can I achieve the same.

Thanks.
Message has been deleted
Message has been deleted

Kamarajugadda Manjula

unread,
Aug 12, 2016, 2:20:22 AM8/12/16
to JSTS devs
any related examples are also welcomed sir.

erik.he...@climate.com

unread,
May 11, 2017, 4:46:51 PM5/11/17
to JSTS devs
Sivaram,

1. Call getArea() on the union of your polygons. 
2. Call getArea() on the intersection of your polygons.
3. Divide the intersection area by the union area and that is your percentage of intersection.

-Erik
Reply all
Reply to author
Forward
0 new messages