View on GitHub

Cesium-gwt

GWT wrappers around some of the Cesium JS library

Download this project as a .zip file Download this project as a tar.gz file

Welcome to the cesium-gwt project.

Demos / Sample Code / JavaDoc

New Release with Major New Features: Cesium-GWT 0.2.0

Cesium-GWT 0.2.0 is now officially released, with support for the following new features: All of these new features are demonstrated in the new GWT Sandcastle demos and sample code

Prior Release: Cesium-GWT 0.1.1

Thanks to Mark Erikson for significant contributions and improvements made in this new release. Mark and I filled out several additional classes and methods, and made some improvements to the basic implementation style. This new release changes a few APIs from our previous 0.1 release, but Java compile-time checking should help you find any required changes very quickly. Some of the new capabilities include the ability to draw new shapes (box, polygon, polygon outlines, circles) and extrude them (make 3D solid or translucent shapes), improved camera controls, callback handling for "picking" primitives (e.g., to click on an extruded circle--a cylinder drawn vertically from the Earth's surface--and get a callback to tell you what you clicked), more input events (we now support but have not fully tested touch events), more Imagery and Terrain providers, methods to adjust imagery colors (e.g., saturation, brightness), Materials handling, some CZML support, and some SkyBox support!

Prior Release: Compatible with Cesium 1.0

This is where I have gradually added GWT classes and methods as needed to support certain GWT-based projects. I have tried to keep the Java version of Cesium APIs closely matched to the JavaScript APIs, so many Cesium JavaScript examples will easily port to a Java (GWT) translation. Not all of the Cesium APIs are implemented though, but if you need additional classes or methods, they are pretty easy to create. Just follow the same pattern. Note how the "Option" classes work (e.g., inner classes CesiumWidget.Options, Camera.FlyToOptions, and classes Label and Billboard), to mimic how some Cesium JavaScript classes take an Object of optional named parameters; and look at how JsCallbacks/EventListeners work (the CesiumWidgetPlayer has a good example for showing the mouse position under the cursor), and also how Enums are implemented.

Also look at the samples to get an idea of how to use cesium-gwt. I recently created a subpackage called "sandcastle" to start to capture samples that mirror the Cesium JavaScript sandcastle demos. I've started with a couple that show off some of the newer capabilities, such as extruded polygons, improved camera controls, and scene morphing. Here's a simple demo page you can create in your own environment with "mvn clean package war:war"

Recent improvements

To do

  1. Add more classes and methods. I implemented only the classes I really needed to have for my development.

  2. Consider writing a translator to translate Cesium JS APIs to cesium-gwt. The translation design pattern is fairly straightforward. Perhaps a modification of the software that generates the Cesium reference documentation could be adapted.

  3. Write JavaDoc! Again, here's where a translator from Cesium's docs to cesium-gwt would come in handy.

  4. Implement test cases.

I don't have a lot of time to work on this, and unless required for my projects, I may not be able to do much except the occasional few hours of personal time. But I would be ecstatic if others wanted to contribute to the above goals.

Support or Contact

Cesium-gwt was created by @richkadel while working on applications for Harmonia Holdings Group, LLC., as an extension of the Apache 2.0-licensed Cesiumjs (http://cesiumjs.org), and is released under the same license.

Having trouble with Pages? Check out the documentation at http://help.github.com/pages or contact support@github.com and we’ll help you sort it out.