You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
I often import feature data that has geometry layout XYZ, but need the coordinates as XY. With all SimpleGeometry implementations except Point, this can be achieved as follows: geometry.setCoordinates(geometry.getCoordinates(), 'XY');
The reason for this is in "src/ol/geom/flat/deflate.js". The function "deflateCoordinate" completely ignores parameter 'stride' and takes over the coordinate in its full length. All other functions correctly use the parameter 'stride' to decide how many dimensions are added to the flatCoordinates array.
Expected behavior point.setCoordinates(point.getCoordinates(), 'XY') converts the coordinate to layout 'XY' as it is the case for all other SimpleGeometry implementations (except Circle, that has no coordinates).
The text was updated successfully, but these errors were encountered:
Describe the bug
I often import feature data that has geometry layout XYZ, but need the coordinates as XY. With all SimpleGeometry implementations except Point, this can be achieved as follows:
geometry.setCoordinates(geometry.getCoordinates(), 'XY');
The reason for this is in "src/ol/geom/flat/deflate.js". The function "deflateCoordinate" completely ignores parameter 'stride' and takes over the coordinate in its full length. All other functions correctly use the parameter 'stride' to decide how many dimensions are added to the flatCoordinates array.
Expected behavior
point.setCoordinates(point.getCoordinates(), 'XY')
converts the coordinate to layout 'XY' as it is the case for all other SimpleGeometry implementations (except Circle, that has no coordinates).The text was updated successfully, but these errors were encountered: