Skip to content
New issue

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

IsValidOp fails to detect a linear ring self-intersection #25

Open
badger3512 opened this issue Feb 6, 2024 · 1 comment
Open

IsValidOp fails to detect a linear ring self-intersection #25

badger3512 opened this issue Feb 6, 2024 · 1 comment

Comments

@badger3512
Copy link
Contributor

The IsValidOp class fails to detect the self-intersections existing in the following LinearRing.

LINEARRING (7 8, 3 8, 1 5, 1 6, 3 3, 7 3, 9 6, 9 5, 7 8)

The following test routine illustrates the issue:

test('linearringintersection_test',(){
    final wkt = 'LINEARRING (7 8, 3 8, 1 5, 1 6, 3 3, 7 3, 9 6, 9 5, 7 8)';
    final ring = WKTReader().read(wkt);
    IsValidOp op = IsValidOp(ring!);
    expect(op.validErr != null,true);
  });

The expected result is:

Ring Self-intersection at or near point (1.3333333333333335, 5.5)

An image of the geometry is shown below.

image-4

@moovida
Copy link
Owner

moovida commented May 1, 2024

Sorry @badger3512 , didn't forget this. Need to find time to check with the java version what is going on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants