Allow geometries to use a shared vertex array

The ol.geom.SharedVertices structure represents a flattened array of vertex coordinates.  This is intended to support optimal WebGL rendering.
This commit is contained in:
Tim Schaub
2013-03-02 18:39:24 +01:00
parent bdfa2cc88c
commit b52d283641
23 changed files with 1086 additions and 217 deletions
+13
View File
@@ -68,6 +68,19 @@ describe('ol.geom.MultiLineString', function() {
});
describe('#getCoordinates', function() {
it('returns an array', function() {
var coordinates = [
[[10, 20], [30, 40]],
[[20, 30], [40, 50]]
];
var multi = new ol.geom.MultiLineString(coordinates);
expect(multi.getCoordinates()).toEqual(coordinates);
});
});
});
goog.require('ol.geom.Geometry');