Commit Graph

1200 Commits

Author SHA1 Message Date
Tim Schaub 13a981c94b Fewer blank lines 2016-01-11 22:03:23 -08:00
Tim Schaub 3cf8618fc7 Prefer single line assignment to 80 character limit 2016-01-11 18:56:08 -08:00
Tim Schaub 59a66c7aaa Remaining valid-jsdoc corrections 2016-01-11 18:56:08 -08:00
Tim Schaub e6f6dcc230 Partial valid-jsdoc corrections 2016-01-11 18:56:08 -08:00
Andreas Hocevar 9f43716723 Merge pull request #4596 from ahocevar/tile-key
Use consistent tile coordinate keys
2016-01-04 19:27:47 +01:00
Petr Sloup 767ac44e99 Make ol.source.Tile#getTilePixelRatio work for all sources
Even for sources which serve dynamic tile sizes based on devicePixelRatio
2015-12-28 13:19:03 +01:00
Andreas Hocevar 300b5cad44 Use consistent tile coordinate keys
Tile coordinate keys from ol.tilecoord.toString() are different than the ones
from Array.prototype.toString(). Both were used, potentially causing problems.
This change makes them consistent and removes the now unnecessary
ol.tileCoord.toString() function.
2015-12-27 17:59:51 +01:00
Andreas Hocevar 38bb1569af Remove no longer needed buffer for direct rendering 2015-12-18 00:27:42 +01:00
Andreas Hocevar 9affb99899 More sensible split between direct and canvas rendering 2015-12-17 10:58:35 +01:00
Andreas Hocevar 80f10ce824 Avoid unnecessary calculation in loops 2015-12-17 00:17:28 +01:00
Andreas Hocevar 4f2df30f1d Avoid clipping by rendering tiles with rotated labels
This only works when the device pixel ratio is 1. Labels are incorrectly
positioned and not at all rotated for other pixel ratios. I cannot find the
cause for this problem.
2015-12-17 00:17:27 +01:00
Andreas Hocevar c1b16217f2 Conditionally render tiles to a separate tile canvas
Because clip geometries are anti-aliased in most browsers, there will be tiny
gaps between tiles. If tiles are rendered to a tile canvas which is then drawn
to the map canvas upon composition, these gaps can be avoided. For rotated
views, it is stil necessary to clip the tile, but in this case a 1-pixel
buffer is used.

This change also brings a huge performance improvement for panning, because
the fully rendered tiles can be reused.

Because of the added cost of using drawImage in addition to replaying the tile
replay group, we fall back to directly drawing to the map canvas when the tile
canvas would be too large, or during interaction/animation when resolution or
rotation change.
2015-12-17 00:17:27 +01:00
Bart van den Eijnden 25e0053a13 Rename defaultSort to numberSafeCompareFunction on ol.array 2015-12-16 13:40:05 +01:00
Bart van den Eijnden e0be143ed5 Always pass on a compare function to sort 2015-12-16 10:54:46 +01:00
Andreas Hocevar 2215f49617 Merge pull request #4472 from ahocevar/layer-filter
Do not ignore layer filter for unmanaged layers
2015-12-01 12:01:58 +01:00
Éric Lemoine 279eae1dba Do not ignore layer filter for unmanaged layers
PR #3883 made `forEachFeatureAtPixel` ignore unmanaged layers. This commit reverts that change.
2015-11-30 17:53:19 +01:00
Frederic Junod 1092f6b2a2 Remove use of goog.dom.createElement 2015-11-23 09:22:39 +01:00
Frederic Junod a4fb2501d8 Remove use of goog.array.sort
Fixes #4160
2015-11-19 16:53:11 +01:00
Frederic Junod bfd33becbc Remove unused local variables 2015-11-17 10:20:40 +01:00
Frederic Junod 764875147a Remove unused local variables 2015-11-17 09:57:56 +01:00
Éric Lemoine f5a148e6b3 Merge pull request #4389 from elemoine/dynamic-params
Smooth transitions on parameter changes
2015-11-13 08:41:42 +01:00
Tim Schaub a8a796f922 Merge pull request #4410 from openlayers/v3.11.x
Merge in changes from the 3.11.1 release.
2015-11-12 16:53:41 -07:00
Andreas Hocevar c5f4710b8d Revert "Merge pull request #4344 from bartvde/issue-2844"
This reverts commit e5c44b37c9, reversing
changes made to 7f4c6e3634.
2015-11-12 19:17:07 +01:00
Éric Lemoine 132861e175 Use interim tiles when changing dynamic parameters 2015-11-12 14:40:35 +01:00
Tim Schaub e8c99e4e63 Allow style function to return a style 2015-11-11 17:21:24 -07:00
Andreas Hocevar 1aea2c2b0c Pass null as forEachFeatureAtPixel layer arg for unmanaged layers 2015-11-09 09:45:21 +01:00
Bart van den Eijnden 979342091a Support different resolutions in x and y direction for ol.source.ImageStatic 2015-10-30 19:27:31 +01:00
Andreas Hocevar 5d264d2bf0 Remove right-handed polygon handling in renderer
Since ol.render.Feature assumes right-handed polygons anyway, this
extra optimization is not needed.
2015-10-28 10:29:04 +01:00
Andreas Hocevar 5832943773 Make changes suggested during the review 2015-10-28 10:29:04 +01:00
Andreas Hocevar 2b2ac47b1f Remove ol.source.TileVector 2015-10-28 10:29:04 +01:00
Andreas Hocevar 80fa26ddd8 Reduce the use of goog.* 2015-10-28 10:29:03 +01:00
Andreas Hocevar 656023e569 Use new createLoadedTileFinder signature
The signature of this method was changed with the introduction of
raster reprojection.
2015-10-28 10:29:03 +01:00
Andreas Hocevar 0e8e104a2d Handle righthanded polygons in format, not source 2015-10-28 10:29:02 +01:00
Andreas Hocevar 29b64d8628 Improve readability and reduce garbage creation 2015-10-28 10:29:02 +01:00
Andreas Hocevar bda3a6803c Use tiles with lower or same resolution as view 2015-10-28 10:29:02 +01:00
Andreas Hocevar 9df280a884 Handle dirty tiles properly 2015-10-28 10:29:02 +01:00
Andreas Hocevar 6e2f82c397 Introduce ol.render.Feature 2015-10-28 10:29:02 +01:00
Andreas Hocevar dbedbc19ee Create replay group for the tile's native resolution only 2015-10-28 10:29:01 +01:00
Andreas Hocevar 4b942bc4f6 Add VectorTile renderer 2015-10-28 10:29:01 +01:00
Petr Sloup ed1e49045a Allow different source and view projection in image layer renderers
To enable image layer reprojection.
2015-10-16 09:28:41 +02:00
Petr Sloup b0694c1e3b Add projection parameter to ol.source.Tile#expireCache and #useTile
This is required to be able to determine which cache the xyz coordinates
refer to (in case we have more caches).
2015-10-16 09:28:41 +02:00
Petr Sloup e0cfa1951a Add projection parameter to ol.source.Tile#forEachLoadedTile 2015-10-16 09:28:41 +02:00
Marc Jansen 9386415633 Remove usage of goog.dom.TagName enum 2015-10-12 20:45:49 +02:00
Frédéric Junod 4cf1ee769e Merge pull request #4202 from fredj/rm_appendChild
Remove use of goog.dom.appendChild
2015-10-01 14:49:15 +02:00
Frederic Junod ef9b64673e Remove unused local variables 2015-10-01 13:38:55 +02:00
Frederic Junod 9b6ad1b36f Remove use of goog.dom.appendChild
Use `parent.appendChild(child)` instead.
2015-10-01 12:06:38 +02:00
Marc Jansen 138adf0509 Remove goog.isNull in renderer classes 2015-10-01 09:17:14 +02:00
Tim Schaub 6bdacced92 Merge pull request #4176 from tschaub/remove-isdefandnotnull
Remove use of goog.isDefAndNotNull().
2015-10-01 00:05:57 -06:00
Frédéric Junod fd729216b5 Merge pull request #4188 from fredj/rm_goog_object_getKeys
Remove use of goog.object.getKeys
2015-09-29 17:33:13 +02:00
Tim Schaub ed3dcd636f Replace !goog.isDefAndNotNull() with falsey checks 2015-09-29 09:32:51 -06:00