Browse Source

change the viewBounds format

tags/2.1.3
Caven Chen 4 years ago
parent
commit
aa70571bbd
1 changed files with 3 additions and 8 deletions
  1. 3
    8
      modules/viewer/Viewer.js

+ 3
- 8
modules/viewer/Viewer.js View File

@@ -147,7 +147,7 @@ class Viewer {
this
)
if (!min || !max) {
return undefined
return 1
}
return Math.abs(min.lng - max.lng)
}
@@ -164,14 +164,9 @@ class Viewer {
this
)
if (!min || !max) {
return undefined
}
return {
west: min.lng,
south: min.lat,
east: max.lng,
north: max.lat
return Cesium.Rectangle.MAX_VALUE
}
return Cesium.Rectangle.fromDegrees(min.lng, min.lat, max.lng, max.lat)
}

/***

Loading…
Cancel
Save