Sunday, May 13, 2007

Researching KML

So I'm on google earth's KML tutorial page. Some highlights and considerations:

Google Earth (GE) can draw some pretty cool polygons and such. However, the edges of these polygons are defined directly by lat/longs. I'm not sure how this will play into generating these coordinates per population as appropriate to the data. The pies would be defined by multiple points, not points all connected to some central point, so centering, etc may be tricky.

GE's KML seems pretty similar to html markup styles. I don't think it'll be too hard to learn. It looks like you can define global styles (<style id="">) that you then can call appropriately.

You can link to stuff on the network as well. Check out "Network Links" in the future. You can link to static stuff (images, another kml file, etc.), but you can link to dynamically generated stuff too. For instance, you can connect to a cgi script. Also, you can send info about the current use (page view, what's highlighted, etc.), then use that info to generate some new kml, then feed that back to the user's GE. This could be a way to incorporate user feedback into the system. But it sounds like it could be tricky.

Another trick: to add html markups, use the CDATA element. Example, add:
...all usual html coded stuff here...
Otherwise, you'll have to escape all the < and >.

No comments: