Address TODOs

To make sure that our binarySearch implementation meets the requirements of
the library, I added more tests for ol.geom.flat.interpolate.lineString, only
to find out that it does not handle line strings with repeated vertices
properly, regardless of what binarySearch implementation is used.
This commit is contained in:
Andreas Hocevar authored and Nicholas L committed 2016-02-03 11:41:41 +13:00
1 parent 1771df0109
commit ebc98ec1bb
3 files changed
+146 -17

No files matched your search

+1
View File
@@ -15,6 +15,7 @@ goog.require('ol.array');
* @return {Array.<number>} Destination.
*/
ol.geom.flat.interpolate.lineString = function(flatCoordinates, offset, end, stride, fraction, opt_dest) {
// FIXME does not work when vertices are repeated
// FIXME interpolate extra dimensions
goog.asserts.assert(0 <= fraction && fraction <= 1,
'fraction should be in between 0 and 1');