Commit Graph

2123 Commits

Author SHA1 Message Date
Tom Payne c6181ea9d1 Render simplified geometries in replay mode 2013-12-09 16:37:33 +01:00
Tim Schaub 4ee9605d61 Using CONSTANT_CASE for geometry type 2013-12-05 14:00:04 -07:00
Tom Payne 1dd5f7f7c8 Merge remote-tracking branch 'openlayers/master' into vector-api 2013-12-05 16:53:04 +01:00
Tom Payne 600cb3a0ff Add @struct annotation where possible 2013-12-04 16:07:39 +01:00
Tom Payne d6dc1a2c6f Don't use WebGL if there is a major performance caveat 2013-12-04 11:58:05 +01:00
Tom Payne 9d57b53c0f Add optional layerFunction to ol.Map#forEachFeatureAtPixel 2013-12-04 00:05:45 +01:00
Tom Payne e9267e401c Pass layer to forEachFeatureAtPixel callback 2013-12-04 00:05:45 +01:00
Tom Payne d7591594ca Allow forEachFeatureAtPixel callback to break out of loop 2013-12-04 00:05:44 +01:00
Éric Lemoine 6f423726a9 Add ol.renderer.Map#forEachFeatureAtPixel 2013-12-02 15:06:19 +01:00
Éric Lemoine 65c922f580 Add ol.renderer.canvas.VectorLayer#forEachFeatureAtPixel 2013-12-02 15:06:19 +01:00
Éric Lemoine e9843ced57 Add ol.renderer.Layer#forEachFeatureAtPixel 2013-12-02 15:06:19 +01:00
Éric Lemoine b98ff1619d Add getRenderGeometryFunction_ 2013-12-02 15:06:18 +01:00
Tom Payne 44a28e3c16 Use ol.vec.Mat4.equals2D in ol.renderer.dom.TileLayer 2013-12-02 09:57:02 +01:00
Tom Payne e1305b4614 Use ol.vec.Mat4.equals2D in ol.renderer.dom.ImageLayer 2013-12-02 09:57:02 +01:00
Tom Payne 2ba5cf6167 Use ol.vec.Mat4.makeTransform2D in ol.renderer.webgl.TileLayer 2013-12-02 09:57:02 +01:00
Tom Payne 20bd020c13 Use ol.vec.Mat4.makeTransform2D in ol.renderer.Map 2013-12-02 09:57:01 +01:00
Tom Payne 6b96cf4ed5 Use ol.vec.Mat4.makeTransform2D in ol.renderer.dom.TileLayer 2013-12-02 09:57:01 +01:00
Tom Payne 432a8d2e19 Use ol.vec.Mat4.makeTransform2D in ol.renderer.dom.ImageLayer 2013-12-02 09:57:01 +01:00
Tom Payne bf08e6afe3 Use ol.vec.Mat4.makeTransform2D in ol.renderer.canvas.TileLayer 2013-12-02 09:57:01 +01:00
Tom Payne 5e5fc85238 Use ol.vec.Mat4.makeTransform2D in ol.renderer.canvas.Layer 2013-12-02 09:57:01 +01:00
Tom Payne 36fee8013a Use ol.vec.Mat4.makeTransform2D in ol.renderer.canvas.ImageLayer 2013-12-02 09:57:01 +01:00
Tim Schaub 1877f92d46 Add forEach method to rtree, use it in feature cache
This saves having to create feature lookup objects and iterate through lookup properties multiple times.
2013-11-27 12:22:33 -07:00
Tim Schaub 8cc4ae8dbd Separate load requests from feature requests
This separates the action of requesting an extent to be loaded from the action of requesting cached features.  The renderer (or any other consumer of a vector source) calls load to request a data extent.  A `featureload` event fires when new features are loaded.  The renderer (or any other consumer) separately asks for cached features given an extent.  This vector source only loads features once, but this separation will also work with sources that make multiple requests for data in different extents.

This also removes the `data` option from the vector source in favor of a `features` option.  Since we no longer have shared data structures for geometries, people can manually create features and pass them to a vector source.  The `addFeatures` method is exported as well.  This is used to add features to a source that don't have a representation on the "remote" (or server).
2013-11-27 12:22:32 -07:00
Tim Schaub ec02e09ce8 Move render intent enum to feature 2013-11-27 12:22:32 -07:00
Tim Schaub bfaed4d52d Moving all style functionality from source to style 2013-11-27 12:20:43 -07:00
Tim Schaub 2000b0af78 Vector layer/source refactor
This moves the feature cache from ol.layer.Vector to ol.source.Vector.  These are the minimum changes required to maintain the existing functionality and make tests pass.  More refactoring to come.
2013-11-27 12:20:42 -07:00
Éric Lemoine 8f361e35dd Do not draw non-loaded icons 2013-11-27 10:03:23 +01:00
Éric Lemoine 0a4fd29c10 Add icon support to canvas vector renderer 2013-11-26 15:25:32 +01:00
Éric Lemoine 317294756a Style function takes a resolution arg 2013-11-26 14:19:24 +01:00
Éric Lemoine 3820caade1 Style function returns an array of styles 2013-11-26 14:19:24 +01:00
Tim Schaub b235fe25ea Return for getFeatureInfoForPixel
In b8a9aeb14e a return was added to `ol.renderer.Layer.prototype.getFeatureInfoForPixel`.  The `ol.renderer.canvas.VectorLayer.prototype.getFeatureInfoForPixel` method needs the same.
2013-11-25 15:29:40 -07:00
Tom Payne b0d5f96b65 Rename ol.render.canvas.Replay#draw to replay 2013-11-25 20:03:21 +01:00
Tom Payne 900bc176ae Avoid clearing canvas twice 2013-11-25 08:58:18 +01:00
Tom Payne 6584ef985f Improve type checking in ol.renderer.canvas.Map 2013-11-24 14:33:47 +01:00
Tom Payne 617635ed80 Improve type checking in ol.renderer.webgl.Map 2013-11-24 14:28:44 +01:00
Tom Payne 9396df54c3 Always use a defined renderGeometryFunction, thanks @elemoine 2013-11-22 11:34:42 +01:00
Tom Payne a570261886 Pass renderGeometryFunction to ol.render.canvas.ReplayGroup 2013-11-22 11:34:41 +01:00
Frederic Junod 6762e70f4c Better canvas sizing handling (canvas and webgl) 2013-11-21 17:08:49 +01:00
Frederic Junod a7bb02b49c Better canvas sizing handling (canvas and webgl) 2013-11-21 14:05:28 +01:00
ahocevar 912ac29f31 Merge pull request #1298 from ahocevar/gfi-callback
The source determines who can do GetFeatureInfo
2013-11-20 07:11:51 -08:00
ahocevar b8a9aeb14e Avoid source check in map renderer
By returning true or false from the layer renderer's
getFeatureInfoForPixel method, we know whether the source
supports GetFeatureInfo or not.
2013-11-20 16:05:00 +01:00
Éric Lemoine efba141bf0 Do not use default style function 2013-11-20 15:35:10 +01:00
ahocevar 0238fa54de The source determines who can do GetFeatureInfo
Now that the ol.renderer.Layer base class has a
getFeatureInfoForPixel method, we have to check whether the
source supports GetFeatureInfo, not the layer renderer.
2013-11-20 13:05:06 +01:00
Tom Payne 6fe7a980f2 Use ol.structs.PriorityQueue template in ol.renderer.webgl.Map 2013-11-20 11:45:49 +01:00
Tom Payne 479ec441ab Improve type checking in ol.renderer.canvas.VectorLayer 2013-11-20 11:45:25 +01:00
Éric Lemoine 215344af71 Set stencil to true in webgl context 2013-11-20 11:45:25 +01:00
Éric Lemoine 93aef958e9 Move arrayBuffer_ to layer renderer 2013-11-20 11:45:25 +01:00
Éric Lemoine 1c03886e1c Rename arrayBuffer_ to renderArrayBuffer_ 2013-11-20 11:45:25 +01:00
Éric Lemoine eead07b0bb Fire pre and postcompose events from webgl map 2013-11-20 11:45:25 +01:00
Éric Lemoine 8d191ca4b8 Fire pre and postcompose events from webgl layers 2013-11-20 11:45:25 +01:00