I couldn't find any example of creating a polygon in Unity, I hope you can help me.
Hi,
Code snippets that show how to create a polygon for the ArcGIS Maps SDK for Unity are completely wrong. This code works for creating a polygon.
ArcGISPolygonBuilder pb = new ArcGISPolygonBuilder(ArcGISSpatialReference.WGS84());pb.AddPoint(x1, y1);pb.AddPoint(x2, y2);pb.AddPoint(x3, y3);pb.AddPoint(x4, y4);
ArcGISPolygon polgon= (ArcGISPolygon)pb.ToGeometry();
Hello,
There are code snippets that show how to create a polygon for the ArcGIS Maps SDK for Unity available on the developers guide pages (see below). Hopefully this will help!
https://developers.arcgis.com/unity/spatial-and-data-analysis/geometry/#polygon
Aangemelde leden kunnen berichten plaatsen, updates volgen en meer. Nieuw hier? Registreer een gratis account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.