CesiumGS / cesium

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

ImageryLayer with `dayAlpha`/`nightAlpha` and `showGroundAtmosphere=false` breaks 2D #12260

Open Jing9010 opened 3 weeks ago

Jing9010 commented 3 weeks ago

What happened?

image

Reproduction steps

...

Sandcastle example

https://sandcastle.cesium.com/#c=dVLfT4MwEP5XGp4gWco2X0xki8s0umSJJhqfeCn0Bo2lJb3Cgsb/3ZaNiXPyRL8f991dm2uFlrQC9mDIgijYkzWgaCr61mNhGuT9ea2VZUKBSYPoJlUHB8UcFNBC6gwoKJZJ2IqitEIVrpg1DaQq7xNExQow3ZZ1fc4xYzNC6c7o6tnoVnAwK+xUHg4qrY7Cge61K0SwGx5eXc/m0aincRRSxnk4RrxwfKaZ8R0rQHR9zaZnrPIkW8m6ZJ6m5zxn3UBOPXlhL1jq/YPRjeIrW2msSzDg5Dsm8bSeEmR9fgH3LSj72BNhlCrivoOsn+lCkBVu/Zpxt6XCuHn6AhPiwpbk81CAELEj/3nRm4FHP2JCfkkrberyVc/vwlk0SL5OPw4KJkGCtpOwHNBbUdXaWNIYGVIaW6hqySxgnDX5O1iaI/ob8dIkHlsTLloi+OLC+yO5ZIiO2TVSvogPSINlEjv9H6t0A7m3+NSCkazzsnK23B5ASmkSu+Nlp9VaZsycVf4G

Environment

Browser: Chrome v129 CesiumJS Version: 1.122.0 Operating System: macOS

ggetz commented 3 weeks ago

Hi @Jing9010, I'm not sure I understand what the issue is you're seeing. Can you add more details about the expected behavior?

CesiumJS is a big project, so we use GitHub for feature requests and bug tracking exclusively. In the future, please take any questions to the Cesium Forum where there are members of the community and developers from the team who can help. Thanks!

Jing9010 commented 3 weeks ago

1.Create an ImageryLayer 2.Set dayAlpha or nightAlpha: imageryLayer.dayAlpha = 0.0 3.viewer.scene.globe.showGroundAtmosphere = false

  1. Change the sceneMode
ggetz commented 3 weeks ago

Ah thank you @Jing9010. I see that this broken behavior only occurs when

  1. dayAlpha or nightAlpha is set, AND showGroundAtmosphere is disabled
  2. There is some delay before morphing to 2D.