Sunday, January 20, 2008

Using SurfacePolygon to render shapefiles

Today I a have working with SurfacePolygon to render shapefiles.
SurfacePolygon takes a set of Positions and creates a BufferedImage that is rendered as a normal tile. That has a good performance and the result image can beautifully overlap the terrain



The above polygons are configured to create images with 256x256 size. The results seems good, but all depends on how much good you want.

Monday, January 14, 2008

The day when Timeline becomes more graphical

This is the new Timeline layer. It is not completely finished but it is more graphical and (at least for me) more beautiful ;)





To create it, I was developed before a new little package called "Widgets" with a mini set of classes implementing: button, image and label.
All them are kinds of widgets and can receive mouse events: entered, exited, left pressed, left clicked, draw and draw end. Depending on these event you can change the properties of the objects: opacity, change its texture (to make feel the button is pressed), font, etc.

Saturday, January 12, 2008

Shapefile support finished

Thanks to the code I was developed for my original Balloon 3D API I just have finised the shapefile suport for WWJ ;) and I'm very happy because the performance is really good.



As I say previously, unfortunately it only works fine for flat world. I take a look in the Polyline implementation to know how to render it taking into account the globe relieve.

Shapefile support started

Today I have started the support for shapefiles in WWJ.


There to group of things:
  • Goods. These are the good things about the implementation:

    • I am adapting the same code I used some time ago in my own 3D API of Balloon Project. That is a good new for me :)
    • The features are loaded "dynamically", not waits until the whole file is read, instead the reader process adds on the fly a new renderable object for each read feature.
    • The implementation uses display list and the performance is pretty good.
    • It allows read points, polygons and collection of geometries (I need to refresh the geometry hierarchy).
    • You can specify the color, opacity and thickness of geometries. When some property that affects its visualization the display list is recreated.


  • Bads. These are the bad new about the implementation.

    • Polygon are not filled.
    • You must to set the globe to a flat globe (vertical exaggeration equal zero). For the moment there are problems with the globe relieve.


Monday, January 07, 2008

...and the Balloon becomes pluggable

Spending some of my vacation days on the Balloon project, finally I almost finished the base platform, composed by three main modules:


  • Core module: Responsibles for the 3D rendering process and interaction with the elements. Here I put some of my own extension to WWJ that helps to improve the layer management, add new object (like AnnotatedIcons), ...

  • Use interface module: Contains the basic GUI for the Balloon with:
    • Layer manager: allows to handle elements as a layer stack, moving elements up/down, creating group of elements, ...
    • Property window: each element has its own properties that are shown and modified through the properties window.
    • A set of basic wizards to import: images (local or remote), WMS layers, icons and annotations.
  • Support module: Contains some third party libraries needed by the GUI (like SwingX).

This part needs some improvements but it current state is very decent.

On the other side, I have started to develop the first plugin for the base platform. This pluggin integrates some geonames capabilities into the Balloon, it allows to search toponyms and put into the globe as annotation.

Once installed the plugin, a new wizard is present in the "pluggins" tab. It allows to search any toponym with the given text (with some filter options).
If the geoname webservices returns any found data, then we can select which one to put in the globe as annotation:
and finally we get his: