CesiumGS / cesium

An open-source JavaScript library for world-class 3D globes and maps :earth_americas:
https://cesium.com/cesiumjs/
Apache License 2.0
13.05k stars 3.51k forks source link

Orthographic camera projection #11955

Open askmyselfwhy opened 7 months ago

askmyselfwhy commented 7 months ago

What happened?

Why orthographic projection so much differs from perspective on big distances from the globe (see images)?

Zooming in-out also feels weird. Also no moon or anything else is rendered in orthographic mode.

The orthographic view was previously the same as perspective. And after updating Cesium library (from one of 2020 versions to the latest) we've got this strange behavior. What was the reason behind it and how can I replicate the same view as in perspective not by digging into the core of the library?

image image image image

Reproduction steps

  1. Go to sandcastle
  2. Zoom in/out, rotate.
  3. Zooming and rotating feel like you are looking through a pinhole at a flat map, but not 3d globe.

Sandcastle example

https://sandcastle.cesium.com/index.html?src=Projection.html

Environment

Everywhere

ggetz commented 7 months ago

Thanks for the report @askmyselfwhy.

The orthographic view was previously the same as perspective. And after updating Cesium library (from one of 2020 versions to the latest) we've got this strange behavior.

Would you be able to identify the release where this has changed? My guess would be around version 1.97.

askmyselfwhy commented 7 months ago

Thanks for the report @askmyselfwhy.

The orthographic view was previously the same as perspective. And after updating Cesium library (from one of 2020 versions to the latest) we've got this strange behavior.

Would you be able to identify the release where this has changed? My guess would be around version 1.97.

I found a release where it's happened https://github.com/CesiumGS/cesium/releases/tag/1.93

Previous releases work fine, like this https://github.com/CesiumGS/cesium/releases/tag/1.92

askmyselfwhy commented 7 months ago

Thanks for the report @askmyselfwhy.

The orthographic view was previously the same as perspective. And after updating Cesium library (from one of 2020 versions to the latest) we've got this strange behavior.

Would you be able to identify the release where this has changed? My guess would be around version 1.97.

I found a release when it's happened https://github.com/CesiumGS/cesium/releases/tag/1.93

Previous releases work fine, like this https://github.com/CesiumGS/cesium/releases/tag/1.92

Probably one of the changes here: https://github.com/CesiumGS/cesium/pull/10063

ggetz commented 7 months ago

Thanks so much @askmyselfwhy!