tileVisible triggers before style is applied
- Dominant language
- JavaScript
- Stars
- 15.7k
- Forks
- 3.9k
- Avg merge
- 4d 6h
- Merged PRs (30d)
- 34
Description
We are using the tileVisible Event on the Cesium3DTileset to style features based on some externally managed maps. This was working fine with the old Model Code. The new Model Code now applies the style after calling tileVisible.
The [documentation](https://cesium.com/learn/cesiumjs/ref-doc/Cesium3DTileset.html#style) also states that `The style is applied to a tile before the [Cesium3DTileset#tileVisible](https://cesium.com/learn/cesiumjs/ref-doc/Cesium3DTileset.html#tileVisible) event is raised`
the relevant code is the following in [Cesium3DTileset.js](https://github.com/CesiumGS/cesium/blob/1.104/packages/engine/Source/Scene/Cesium3DTileset.js#L2911) raises the Event before Update. If i call update before tileVisible.raiseEvent it works as expected.
[Sandcastle example](https://sandcastle.cesium.com/#c=bVRLc9owEP4rKhfsCcikvYFhOkNoe6CPCTQnX4S9YDWy5JFkHsnw37uSHzVNOCBp9X27++2unCppLDlyOIEmcyLhRJZgeFXQJ28LkkHqz0slLeMSdDIIZ4lMPc9yAQYsEtmJcdtS6+XTw7a+pnutit9aoC9Kow0rSgEPzLLoBhc16G4TNd7pH6NkHbXOk5oUJNBS84JbfgRDWZYFDdrBWqKxFwG3qvohN+46eE0kwV+qhNJkSoZ+g6lqyDDoMJHXXuQXpYqtamON+p6/Acu4PPziNs0fmTxAMBmNP9LJ6DuzOS3YObifTOiEjNuq0Z2qpKNsyhw0UI38yowIgsKwL8OtT9zwnQCndHUEadfcWCyCDnwuIZkvyCshtRS+Dz44K2VCY1KXr4+r1Y+w0emUutbhPzpwrfPQ5ji7Be2B2UqDWYM82ByxDYzeXnSsPZYwEDgQHLGTGS7xfz7QdncXki6ZJpZ3egD7pQYHPKR1Q+Zd49yReilduGu7eaPWydIVNMhr08TBaBD7mVi0xM+8KJW2pMLpxNm0gLPJLA7jrkqfsfSpMWHjJI761DjjR8Kz+TvPg6SCGYM3+0qIDX+BZLCII8S/oQrlR+bnEbRgFwfL7xfr2kgpjSM8vs+0Sokdw2CdktiAgNSSDB/WeMelQ6nScuzjtJ04HK7GtIWzxVmXrIDhiByZqGBKag+QbdvpbsBL5lfEL3OlDBBG2pdN6dCrq6n/knE5x1yWFX4jLiW4MuWQPu/UGevTT9GbIcPgOcvUyaA3sqm3N8p7+78)
Contributor guide
Research direction
Start in packages/engine/Source/Scene/Cesium3DTileset.js around line 2911 and reproduce the ordering with the linked Sandcastle example. Check when the style update occurs relative to tileVisible.raiseEvent, then verify that tileVisible observes the applied style as stated in the Cesium3DTileset documentation.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100