Commit Graph

119 Commits

Author SHA1 Message Date
Tom Payne
7ff95adbb1 Add ol.geom.Geometry 2013-11-20 11:41:06 +01:00
Tom Payne
4e65fefc00 Move vector code out of the way 2013-11-20 11:39:21 +01:00
ahocevar
ed09173730 Deep clone geometry coordinates
Our geometries are mutable, so they can be modified without
creating garbage by changing coordinates in place and calling
setGeometry afterwards. But this also means that we need to
create a deep clone of the coordinates.
2013-11-12 11:36:40 +01:00
Paul Spencer
bada596b45 Add default stability level to docs of exported things. 2013-10-24 18:20:24 -04:00
Tim Schaub
9b47c15bd8 Make geometries event targets
Previously, the tests were using eql to make assertions about matching geometries.  This is inappropriate for structures with circular references (as with goog.events.EventTarget);
2013-10-03 12:28:34 -06:00
Tim Schaub
1aa83e133b Remove dimension property from geometries
This was only necessary when using the shared vertices structure.
2013-09-27 23:18:34 +01:00
Tim Schaub
563918d58d Clone should not share bounds 2013-09-27 23:18:34 +01:00
Tim Schaub
33457c48de Add transform method to geometries
In the typical sequence of parse-transform-render the most efficient place to transform coordinate values is deep within the parser immediately after values have been read (this would avoid a second pass over whatever structure is used to back geometries).  To accomplish this transform during parsing, we could add back parser read options to pass the transform function around.

Until then, a transform method on geometries is straightforward to implement.  This means we do a second pass through coordinate structures to transform, but this is typically done only once immediately after parsing.
2013-09-27 23:18:34 +01:00
Tim Schaub
2850c761cf Remove use of shared vertices in geom package 2013-09-27 23:18:17 +01:00
ahocevar
f05629b3c3 Work with clones rather than the original features 2013-08-29 16:50:51 +02:00
ahocevar
56ac30de91 Exposing ol.geom.GeometryType
This is necessary for using ol.filter.Geometry.
2013-05-31 15:04:55 -06:00
Tim Schaub
cae925ad1f Correct spelling (thanks @fredj) 2013-03-04 21:04:59 +01:00
Tim Schaub
b52d283641 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.
2013-03-02 18:39:24 +01:00
Tim Schaub
0015e466dc Allow instanceof checks for geometries 2013-02-19 23:21:05 -07:00
Tim Schaub
89bc69ccc1 Types for rings and mixed collections 2013-01-21 17:56:12 -07:00
Tim Schaub
6ef2184c83 Geometry type enumeration 2013-01-21 17:46:41 -07:00
Tim Schaub
b4d44f815f Add getBounds to geometry 2013-01-21 12:59:04 -07:00
Tim Schaub
fd0a5f3622 Point, linestring, and linearring coordinates as Float32Array 2013-01-18 15:57:48 -07:00
Tim Schaub
997c7145ab Bare bones geom package 2013-01-07 01:34:33 -05:00