0

We are using the .NET TopologySuite to solve various tasks to do with Geometries such as Polygons.

However, we are stuck in trying to find a way for when given a polygon, how do you expand/enlarge that same polygon by say an amount such a 1 km/100 meters etc. using the .NET TopologySuite library.

user2981411
  • 859
  • 12
  • 34

1 Answers1

0

Given that your polygon's (named poly) coordinates in meters as well you simply call var bufferedPoly = poly.Buffer(1000); for an enlargement of a km.

If they are geographic (lat/lon) you have to apply some reprojection first (e.g. using Proj.Net), compute the buffer, and reproject back to your geographic coordinate system.

FObermaier
  • 832
  • 5
  • 12
  • Thanks for your response. Our polys are GeoJson (lat/lon). Do you know of any examples of how to do this as we are quite new to this. We are also wiling to pay for the time if someone could assist us. – user2981411 May 11 '20 at 12:49
  • Have a look at https://learn.microsoft.com/en-us/ef/core/modeling/spatial#srid-ignored-during-client-operations – FObermaier May 12 '20 at 09:02