I got my first pie working! It looks good. Not oblong anymore. And I figure using 360 vertices should make generating pie pieces of any size easier. I don't think it adds that much bulk to the code either, but if it's a problem we can always go down to 20 or so points.
I placed the label and pie pieces in different folders so you can click off the labels easier. Here's the KML.
Showing posts with label KML. Show all posts
Showing posts with label KML. Show all posts
Sunday, June 3, 2007
Lat and Long in KML
While you can enter coordinates in "lat, long" pairs in the finder, in KML, within the tag, the order is "longitude, latitude, altitude".
Tuesday, May 29, 2007
Playing around with Google Earth
Notes:
You can easily move placemarks by accessing their 'properties' then clicking and dragging. You can NOT easily move polygons in the same manner. Maybe that should be a design consideration.
Found a great application that makes all sorts of graphs in GE, called GE-Graph.
He (?) makes the circles as groups of 21 points (first and last the same), so not a true circle.
If you want multiple placemarks within the same file, they must be enclosed by a <Document></Document> tag. Otherwise, GE complains about having too many 'roots'.
Within the <Document> tag you can define a lot of styles using <style id="foo"></style> then reference those styles in the document using <styleUrl>#foo</styleUrl>.
Within a <Placemark> you can only have one point, polygon, etc. Otherwise, it only shows the last one. Unfortunately you can't click on polygon's to view their properties or description. It seems like the easiest way is to create two placemarks for each location. One that is a point, that the user can click on easily, the other the pie chart. Put these data in different folders (<Folder></Folder>) so you can easily turn off the labels.
You can easily move placemarks by accessing their 'properties' then clicking and dragging. You can NOT easily move polygons in the same manner. Maybe that should be a design consideration.
Found a great application that makes all sorts of graphs in GE, called GE-Graph.
He (?) makes the circles as groups of 21 points (first and last the same), so not a true circle.
If you want multiple placemarks within the same file, they must be enclosed by a <Document></Document> tag. Otherwise, GE complains about having too many 'roots'.
Within the <Document> tag you can define a lot of styles using <style id="foo"></style> then reference those styles in the document using <styleUrl>#foo</styleUrl>.
Within a <Placemark> you can only have one point, polygon, etc. Otherwise, it only shows the last one. Unfortunately you can't click on polygon's to view their properties or description. It seems like the easiest way is to create two placemarks for each location. One that is a point, that the user can click on easily, the other the pie chart. Put these data in different folders (<Folder></Folder>) so you can easily turn off the labels.
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 >.
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 >.
Subscribe to:
Posts (Atom)