Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed a crash when loading OSM buildings with shadows enabled #9172

Merged
merged 1 commit into from
Sep 26, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
- Fixed an issue where Plane doesn't rotate correctly around the main local axis. [#8268](https://github.com/CesiumGS/cesium/issues/8268)
- Fixed clipping planes with non-uniform scale. [#9135](https://github.com/CesiumGS/cesium/pull/9135)
- Fixed an issue where ground primitives would get clipped at certain camera angles. [#9114](https://github.com/CesiumGS/cesium/issues/9114)
- Fixed a crash when loading Cesium OSM buildings with shadows enabled. [#9172](https://github.com/CesiumGS/cesium/pull/9172)

### 1.73 - 2020-09-01

Expand Down
6 changes: 2 additions & 4 deletions Source/Scene/ShadowMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -1518,10 +1518,8 @@ function updateCameras(shadowMap, frameState) {
frameState.shadowState.nearPlane,
shadowMap.maximumDistance
);
far = Math.min(
frameState.shadowState.farPlane,
shadowMap.maximumDistance + 1.0
);
far = Math.min(frameState.shadowState.farPlane, shadowMap.maximumDistance);
far = Math.max(far, near + 1.0);
} else {
near = camera.frustum.near;
far = shadowMap.maximumDistance;
Expand Down