mirror of https://github.com/apache/lucene.git
LUCENE-7955: GeoDegeneratePath did not compute endpoint bounding planes properly.
This commit is contained in:
parent
277bc3a94b
commit
c317ad8c1f
|
@ -119,20 +119,20 @@ class GeoDegeneratePath extends GeoBasePath {
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
// Starting endpoint
|
// Starting endpoint
|
||||||
final SegmentEndpoint startEndpoint = new SegmentEndpoint(currentSegment.start,
|
final SegmentEndpoint startEndpoint = new SegmentEndpoint(currentSegment.start,
|
||||||
new SidedPlane(currentSegment.startCutoffPlane));
|
currentSegment.startCutoffPlane);
|
||||||
endPoints.add(startEndpoint);
|
endPoints.add(startEndpoint);
|
||||||
this.edgePoints = new GeoPoint[]{currentSegment.start};
|
this.edgePoints = new GeoPoint[]{currentSegment.start};
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
endPoints.add(new SegmentEndpoint(currentSegment.start,
|
endPoints.add(new SegmentEndpoint(currentSegment.start,
|
||||||
new SidedPlane(segments.get(i-1).endCutoffPlane),
|
segments.get(i-1).endCutoffPlane,
|
||||||
new SidedPlane(currentSegment.startCutoffPlane)));
|
currentSegment.startCutoffPlane));
|
||||||
}
|
}
|
||||||
// Do final endpoint
|
// Do final endpoint
|
||||||
final PathSegment lastSegment = segments.get(segments.size()-1);
|
final PathSegment lastSegment = segments.get(segments.size()-1);
|
||||||
endPoints.add(new SegmentEndpoint(lastSegment.end,
|
endPoints.add(new SegmentEndpoint(lastSegment.end,
|
||||||
new SidedPlane(lastSegment.endCutoffPlane)));
|
lastSegment.endCutoffPlane));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue