Adding CZML Examples to Sandcastle

As part of a University of Pennsylvania course on open-source software development, Adam and I have been working on adding CZML examples to Sandcastle [3027].

Our existing examples can be found on Sandcastle here, as all of the files under the “CZML” tab.

We’ve submitted a pull request [3050] and would love some community feedback on the work we’ve done thus far.

Thanks for this contribution, Tiff and Adam!

Everyone - we plan to merge this today. Please let us know if you have any requests for CZML examples.

Thanks,

Patrick

Those are some great examples. Thanks for taking the time to put
those together.

If you're looking to add a few more I have three ideas. I think an

example that uses the orientation property would be very useful.
I’ve noticed several questions about this on the mailing list. I
also think an example that uses relative reference frames would be
useful since I was never able to figure this out myself. E.g. using
referenceFrame: “#otherObjectID”. Finally, I think an example that
uses Cesium Sensors would complete the examples package.

Best Regards,
Evan

Excellent examples, and made me rethink my display of ‘catch details’ for a fishing vessel.

Would love to see how to apply a time dynamic to a rectangle… (my own tests have not yet shown the results I’d like) I’m thinking that the height of a rectangle reflects the kg’s of fish caught in that region : At time point x, the rectangle height is y…

Thanks,

Brian

Woot !

I got it :

{
  "id" : "XHAG - ILL",
  "name" : "XHAG Catch Details",
  "description" : "This is the html description of the catch @ XHAG<br/><br/>We like Grenadier best!!!",
  "rectangle" : {
    "availability":"2007-07-14T00:00:00Z/2007-07-31T23:59:59Z",
    "show" : true,
    "coordinates" : {"wsenDegrees" : [-61,-50,-60.5,-49.75]},

   
    "height" : {
          "interpolationAlgorithm":"LAGRANGE",
          "interpolationDegree":1,
          "epoch":"2007-07-14T00:00:00Z",
        "number":[
            0,0,
            86400,5000,
            172800,10000,
            259200,21060,
            345600,31060,
            432000,51060       
        ]},
    "extrudedHeight" : 0,
    "fill" : true,
    "material" : {"solidColor" : {"color": {"rgba" : [0, 255, 255, 25]}}
    },
    "outline" : true,
    "outlineColor" : {"rgba" : [127, 127, 127, 50]}
  }
}

Just need to do some magic with extrudedheight in order to allow different coloured boxes for different species caught.

Would be awesome if you do do this :

“number”:[
0,0,
86400,+5000,
172800,+5000,
259200,+11060
]

ie the value is accumulated from whatever it’s current value happens to be…

Glad you figured it out. Unfortunately, the notation you suggest won’t work because a leading plus sign is invalid JSON. It may be possible to do something like have an “accumulatedNumber” property instead of number to indicate new values are offsets, but the packetized nature of CZML might make that hard to implement on the client. Food for thought when we start working major improvements to CZML again.