Closed halset closed 3 years ago
LineSegment.pointAlong
(and other methods on LineSegment
) create a new Coordinate
even though both coordinates of the segment are of type CoordinateXY
. Changing this fixes the problem for me, but perhaps there is a better way?
Sigh... yes, the handling of Coordinate subclasses is imperfect, and needs work. Thanks for pointing this out.
I think maybe one part of the solution is to provide create
methods on Coordinate and subclasses, which instantiate a Coordinate of appropriate type.
@dr-jts I have sketched one possible solution over at https://github.com/locationtech/jts/pull/636. It introduces a non-static Coordinate.createEmptyCopy
that return a Coordinate
of the same type.
Created a new pull-request to fix signature/agreement-stuff. More green marks on this one. #637.
Fixed by #637
Looks like
Densifier
on a 2d line convert it to a 3d line. It would be better if it would keep the dimension.This got me in to a problem with a GeoTools transformation failing.