enter image description hereQuestion: When drawing a polygon in Google Earth with latitude, longitude and elevation values at each node, how do you ensure that the surface area of the polygon also represents the desired elevation in relation to the earth's surface (interpolated between the nodes)? And, not have the surface area tangent to the nodes.

At the moment, when I draw a polygon over the earth at 800000 m absolute, it looks like this: enter image description here

I would like the surface to be the same height as the perimeter of the polygon or to have the surface interpolated between the nodes. So, for example, if I had an inclined plane stretching over the ground where one end is 50 m elevation absolute and the other end is 500 m elevation absolute, the area enclosed in the polygon would represent the interpolated z value. At the moment, it is clearly not the case as can be seen in the picture.

I suspect it would be a setting in Google Earth or there is something in the KML code that can be manipulated..

  • I was thinking that I could slice up the polygon into lots of smaller and skinnier ones, which would take a long time to do. But I am hoping that there is a much better option to what I thought is a common problem and would expect that it has been solved. I haven't found anything yet though.
    – LHo
    Feb 11, 2016 at 2:26
  • 1
    Slice it ln smaller triangle s
    – FelixIP
    Feb 11, 2016 at 3:25

4 Answers 4


Currently, it is forcing the polygon to draw at an absolute elevation (looks to be above sea floor?) You can clamp it to the surface, which will essentially 'drape' it over your elevation / DEM. To fix the issue the KML syntax is


If you could post some of your raw code, might be able to help with implementing it, but this is the best I can come up with without seeing the raw code.

  • The KML code for the Placemark is: <Placemark> <name>test</name> <styleUrl>#msn_ylw-pushpin</styleUrl> <Polygon> <extrude>1</extrude> <tessellate>1</tessellate> <altitudeMode>absolute</altitudeMode> <outerBoundaryIs> <LinearRing> <coordinates> 144.0538810680181,-39.95630263372699,100 144.2132217077547,-39.62999508788247,1000 143.2761194673139,-39.66253056454278,1000 143.9607061784959,-39.96100446490908,100 144.0538810680181,-39.95630263372699,100 </coordinates> </LinearRing> </outerBoundaryIs> </Polygon> </Placemark>
    – LHo
    Feb 11, 2016 at 4:18
  • I'm not sure how to post it so it looks normal with nominated rows etc.
    – LHo
    Feb 11, 2016 at 4:20
  • switch your altitude mode code to: <altitudeMode>clampToGround</altitudeMode> Let me know if that works
    – geodranic
    Feb 11, 2016 at 4:21
  • Wouldn't that make all nodes go to ground level? The intention is to represent an imaginary inclined surface suspended in the air, where the surface inside the polygon also represents elevation. So if all nodes were at 1000 metres absolute, then the area enclosed should also represent 1000 metres.
    – LHo
    Feb 11, 2016 at 4:24
  • 1
    None of the altitude modes seem to fix the issue :-(. The surface inside the nodes still won't stay to the same elevation datum.
    – LHo
    Feb 11, 2016 at 4:31

The way I approached this problem is quite laborious using csv files but I'm working on a quick method using Python.

If you have the csv file with three columns being lat, long and z, open it up in a text editor, just copy and paste it into the kml between the coordinate tags.

If your data is not in wgs84 (lats, longs, z), the it's just a matter of reprojecting in gis, appending coordinate data to to the layer and save it as csv. Easy but time consuming.


I've solved this issue now. I've created a python script that generates little shapes with 4 sides each side having x length. I can set x = input() e.g. x = 100 metres. The surface area enclosed in the extents of a large polygon now has much greater accuracy re. representing absolute height relative to the earth's shape. I'm able to generate a polygon given some data inputs, by generating tens of thousands nodes to make thousands of squares in a maximum of 10 seconds and have it auto-open in Google Earth. Say a shape is I = 2400 wide and J = 15000 long. The whole polygon is modeled by a series of lines running in I and J directions (generally running across each other but not necessarily perpendicular to each other). e.g.

x = 100
i = I/x
j = J/x

Then it's just a matter of running a loop to trace this shape:

shapeTracer = [
[1,1,2,2,1], #i lines
[1,2,2,1,1]  #j lines

thus creating complete squares that enable GoogleEarth to create polygons. Note that once a little polygon is generated, a new little polygon must be created, which would be something like:

shapeTracer = [
[1,1,2,2,1], #i lines
[2,3,3,2,2]  #j lines

and so on.

I'm guessing this idea can be applied to generating all kinds of shapes such that the area inside a polygon represents accurate height so the other code will need to be written as appropriate. If anyone has a better way of achieving the same goal, please I would love to know about it. If anyone is interested in knowing more about what I've done, please ask :-)

  • Hi Joe, I am working on the same problem, although my polygons will always be circles. I do believe it should be possible to approximate my solution by using concentric circles of increasing radius to fix the resulting surface at the required altitude. However, I can't seem to get the kml syntax right for what I am trying to achieve. Could you possibly post a screenshot of your Google Earth view and the kml for one of the "draped" polygons, please? Thanks for your help! M May 6, 2016 at 21:53
  • Hi M, I won't be available at the computer for a few hours. But as an immediate thought, the way I would go about that is creating the coordinates and heights of the circle perimeter using code (like in Python) then put it in the kml coordinate section. I can generate the coordinates for you if you like? It's just a matter of understanding the math logic behind it so to write the code for it.
    – LHo
    May 6, 2016 at 22:06
  • @CptReynolds I added an answer to your question. Was this the kind of thing you were after? Or is there some other way I could help?
    – LHo
    May 7, 2016 at 2:30
  • 1
    Hi Joe, thanks very much - that helps a lot! Originally I thought I could build polygons that essentially are dome-shaped (or approximations thereof), but it looks like I will have to "stitch" these surfaces together from individual polygons. Your code snippet seems to confirm this. Thanks very much for your help! Much appreciated. May 7, 2016 at 20:45
  • 1
    for anyone interested, I put the code in github. It's an OLS_Engine to produce obstacle limitation surface for an airport in Google Earth. github.com/LHoBiz/ols_engine
    – LHo
    Dec 7, 2021 at 14:10

Simple just use spheres formula and you will got the estimated land mass of particular area on earth from centre of earth's So you compared specific gravity of that area and Also the forces experienced by that area due to rotation of earth Now by this we calculate moment of that part of earth's according to fault lines of earth's and found the next earthquake date All the worldwide science foundation are challenged against this technology

  • Could you please show me what this looks like with a shape (polygon) in Google Earth? Code or picture ...
    – LHo
    Oct 29, 2017 at 2:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.