Pass tolerance to ol.render.canvas.ReplayGroup constructor

This commit is contained in:
Tom Payne
2013-12-17 17:46:01 +01:00
parent 79ade07fb7
commit 76bddcf042
2 changed files with 10 additions and 2 deletions

View File

@@ -199,7 +199,8 @@ ol.renderer.canvas.VectorLayer.prototype.prepareFrame =
if (!goog.isDef(styleFunction)) {
styleFunction = ol.layer.Vector.defaultStyleFunction;
}
var replayGroup = new ol.render.canvas.ReplayGroup(pixelRatio);
var tolerance = frameStateResolution / (2 * pixelRatio);
var replayGroup = new ol.render.canvas.ReplayGroup(pixelRatio, tolerance);
vectorSource.forEachFeatureInExtent(extent,
/**
* @param {ol.Feature} feature Feature.