We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I am trying to get the intersection between a rectangle and a polygon.
However, the result is always { POLYGON EMPTY } What am I doing wrong?
{ POLYGON EMPTY }
var wktreader = new WKTReader(); var polygon = wktreader.Read(@"POLYGON ((-62.327500000000008 77.777166176470587, -62.327500000000008 191.08, -39.425176714633878 191.08, 30.449401394787785 111.06902734290135, 34.240621449176217 85.17199763498823, 32.474968591813237 66.628747810197453, 29.724407935551895 56.755281980420541, 10.963366463822565 52.502595315049426, -62.327500000000008 77.777166176470587))"); var boundingbox = wktreader.Read(@"POLYGON ((-52.5 -34, -52.5 34, 52.5 34, 52.5 -34, -52.5 -34))"); var result = boundingbox.Intersection(polygon); // =>{ POLYGON EMPTY } var resultInverted = polygon.Intersection(boundingbox); // => { POLYGON EMPTY }
The text was updated successfully, but these errors were encountered:
The given polygon and bounding box don't intersect:
Sorry, something went wrong.
FObermaier
No branches or pull requests
I am trying to get the intersection between a rectangle and a polygon.
However, the result is always
{ POLYGON EMPTY }
What am I doing wrong?
The text was updated successfully, but these errors were encountered: