problem making proper cxml with python.

Hi,

I’m trying to visualize a polyline in cesium via czml.

The czml I’m trying to load is available at :

[https://gist.github.com/ae4c6bf491949e711ab7](https://gist.github.com/ae4c6bf491949e711ab7)

unfortunately i’m not able to visualize it cesium.

Do you have any clue on what is wrong with my file?

here is an attempt to generate the data and visualize them within an ipython notebook.

http://nbviewer.ipython.org/gist/epifanio/232f1f7ae3212ca68353/cesium-czml-test.ipynb

Thanks for your help!!!

You need to define a polyline. Something like this:

[

{

“version”: “1.0”,

“id”: “document”

},

{

“polyline”: {

“positions”: {

“cartographicDegrees”: [

-75.0, 43.0, 0.0,

76.92579469113619, 29.321495195542337, 0.0

]

}, “id”: “test”

}

}

]

``

Scott

I made one mistake in the example. The line identifying the polyline should be on the next line.

[

{

“version”: “1.0”,

“id”: “document”

},

{

“polyline”: {

“positions”: {

“cartographicDegrees”: [

-75.0, 43.0, 0.0,


76.92579469113619, 29.321495195542337, 0.0

]

}

}, “id”: “test”

}

]

``

Thank you Scott!

i managed to write a proper polyline using your code as template :

http://nbviewer.ipython.org/gist/epifanio/c45fa0c6a6cbc98484ea

For now I’m trying to study the CZML format to display simple geometries (points, line, polygons) with associated attributes.

I found this resources useful :

https://github.com/AnalyticalGraphicsInc/cesium/wiki/CZML-Guide

and https://github.com/AnalyticalGraphicsInc/czml-writer/tree/master/Schema

Which are good resource.

But will be great to have a test file from where to learn the CZML syntax, something like :

https://developers.google.com/kml/documentation/KML_Samples.kml

from the :

https://developers.google.com/kml/documentation/kml_tut?hl=en