Calculate 2d area of a polygon in wgs84

Open
#302 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
java
Domain
backend

Research direction

Start with MultiPath.calculateArea2D(), the Polygon methods, and GeometryEngine's static methods, then review the linked API documentation for spatial-reference or projection support. Done means establishing and documenting an API path that returns a WGS84 polygon's area in square meters or another clearly defined metric unit.

Written by the indexing model from the issue text.

Description

I have a polygon in wgs84. If I use the method polygon.calculateArea2D(), the result is in angular units (according to the documentation). Naturally I would like to have the results in square meters or similar.

It seems to me that the polygon has to be projected to webMercator spatial reference system. However, I cannot find such method in the Polygon's list of methods or the static methods of GeometryEngine.

Dominant language
Java
Stars
710
Forks
268
Avg merge
7d 23h
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Esri/geometry-api-java

All issues in Esri/geometry-api-java

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.