I have a database with a lot of GeoJSON, mostly representing roads and buildings. This GeoJSON is displayed on a map based on a chosen location, i.e. you choose a point on the map and the roads and buildings near to that location are displayed.
At the moment anything which intersects with a circle around the selected point is displayed. However, I'm at the mercy of the underlying dataset in terms of what is actually displayed. For example, if I select a point next to a long road, then that entire road is displayed.
What I would like to do is truncate the geometry displayed based on the circle, so that if there's a long road I only display the portion of the geometry that is contained within the intersection circle.
How can I do this? I'm not even sure where to start.
Ideally I'd like to do this in .NET as my backend is using .NET core and if I can do it server side I won't have to implement it for each client individually.