-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
Add custom properties to CZML files #5105
Conversation
Merge latest Cesium into master
…t primitive values.
One outstanding item to consider - the change mentioned in #3548 which makes GeoJSON properties into |
Thanks heaps @shunter. I've checked this in TerriaJS and it all works, so I'm very happy with your updates! :-) |
I plan on looking at this ASAP. |
Note that this PR includes #5118 to fix deployment on this branch. Merge that PR first. |
CHANGES.md
Outdated
@@ -21,6 +22,7 @@ Change Log | |||
* Fixed a bug in `ModelAnimationCache` causing different animations to reference the same animation. [#5064](https://github.com/AnalyticalGraphicsInc/cesium/pull/5064) | |||
* Fixed a bug that caused an exception in `CesiumInspectorViewModel` when using the NW / NE / SW / SE / Parent buttons to navigate to a terrain tile that is not yet loaded. | |||
* Added support for an orthographic projection in 3D and Columbus view. Set `projectionPicker` to `true` in the options when creating a `Viewer` to add a widget that will switch projections. [#5021](https://github.com/AnalyticalGraphicsInc/cesium/pull/5021) | |||
* Added support for time-varying properties in CZML [#3162](https:/github.com/AnalyticalGraphicsInc/cesium/issues/3162). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be updated and corrected.
Awesome work here @shunter. I knew I'd win that war of attrition if I held out long enough 😈 I did an initial look over the code and nothing jumps out at me except for the GeoJSON/KML issue (but I'll do another pass). I don't have a good answer yet so this is just me thinking out loud. The GeoJSON change, while minimal, seems to be a fairly significant breaking change. In isolation, I am okay with it, but it brings up an issue regarding KML. KML currently dumps some properties into I guess the fundamental question is, did we change the GeoJSON behavior just because it was using As for |
I'll also add my own apology for this not being done years ago. Especially since it's only ~100 lines of code in CZMLDataSource (albeit @shunter did a bunch of |
OK, I added I also added a sandcastle example that shows some ideas for how custom properties, specifically time-varying ones, can be useful. Unsurprisingly, it starts to look a bit like Scalars in STK Components. |
Also, I know we've discussed this for years, but to make a note of it for the future - custom properties will be a key part of computed time-varying strings, using some kind of interpolation syntax, e.g. for data display-like labels, such as showing the speed of an object as a label attached to it. |
Spoke to @shunter offline and he agrees that keeping KML the way it is is the right choice for now. The Sandcastle example could probably be a little better from a viz standpoint, but that can be improved in future PRs. Thanks @RacingTadpole and @shunter and sorry again for this taking so long to get in. |
Awesome, thanks guys! |
Nice! This is Cesium forum post worthy. Can someone post it? |
Includes and replaces #3548. See #3548 for additional commentary. Thanks to @RacingTadpole and @kring for starting this, and sorry for the lengthy delay.
This builds on their work to add detection of the type of custom properties, which enables sampled custom properties that work just like built-in properties. I also added custom properties to the validation document.
Related czml-writer PR (I will merge that after this goes in) - AnalyticalGraphicsInc/czml-writer#129