AnalyticalGraphicsInc/cesium — pull request #207 by mramato (2012-09-04 18:31:35+00:00)
Title: Finish SunPosition

I use the term "finish" loosely since I'm sure we'll need further functionality once we support support multiple CBs.

1. Change SunPosition to a class instead of a static object.
2. Rename `compute` to `update`; `update` does not return any data but rather sets properties on the `SunPosition` instance.
3. Flesh out documentation.
4. Optimize performance and reduce memory pressure. We no longer create throw-away instances.
5. Update CHANGES

If for some reason we're not happy about changing this to a class, we can change it back to a function, but instead of returning an object literal, I would instead just return the Sun's position and people can compute the other values from that; this way we don't have to worry about creating a new object literal every time we compute. We only use position in the code right now anyway.