Fix cruft on kml scale output
This commit is contained in:
@@ -2484,7 +2484,9 @@ ol.format.KML.writePolyStyle_ = function(node, style, objectStack) {
|
|||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
ol.format.KML.writeScaleTextNode_ = function(node, scale) {
|
ol.format.KML.writeScaleTextNode_ = function(node, scale) {
|
||||||
ol.format.XSD.writeDecimalTextNode(node, scale * scale);
|
// the Math is to remove any excess decimals created by float arithmetic
|
||||||
|
ol.format.XSD.writeDecimalTextNode(node,
|
||||||
|
Math.round(scale * scale * 1e6) / 1e6);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user