Load multiple CZML datasources?

Hey guys, is it possible to load multiple CZML data sources and display them all at the same time? The examples I’ve seen so far ( including the drag drop extension) removes all data sources before rendering the new one. Ideally, I would be able to load in multiple CZML files (either static or dynamic) and then allow the user to toggle on and off.

I’m using version b20.

Also, I cannot get CZML files to load and display in the CesiumWidget (not the viewer). I looked at and tried most (if not all) of the example code here in the forum on the topic. I’m not seeing any errors reported from the browser, they just don’t render. If anyone has a working example using b20 I’d appreciate a look at it.

Thanks in advance.

I am facing the same problems ( mutiple CZML loadding + Loading through Widget). Please let me know if you could resolve the same. Thanks.

Yes, you can load multiple CZML data sources at the same time. The viewerDragDropMixin lets you control this functionality with the “clearOnDrop” option, which defaults to true, but you can override it:

viewer.extend(Cesium.viewerDragDropMixin, { clearOnDrop : false });

CesiumWidget is the lowest-level widget in Cesium, and doesn’t handle CZML, or any data source visualization, itself. You can build that functionality on top of it, however, by constructing your own DataSourceCollection, adding your desired DataSources to that collection, creating a DataSourceDisplay, then subscribing to the clock’s onTick event in order to update the DataSourceDisplay.

Given all that, you may find it easier to use the Viewer widget and disable the subwidgets you don’t want by turning them off.