Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have a polygon on my map and I want to resize it in that way I add X km to all of the vertexes. Any idea?

share|improve this question
    
Resize relative to what? Adding N kilometers to the y dimension and the x dimension of every vertex will simply move the polygon farther away from the zeropoints of the x and y axes of the projection (for latitude, the equator, for example). –  MappingTomorrow Jan 30 '13 at 21:50
    
You do realise that for most polygons this will result in a modified shape? –  lynxlynxlynx Jan 30 '13 at 21:52
    
I want to do the same like this: obj.geometry.resize(2, obj.geometry.getCentroid() ); instead of 2 there will be x-km. I'm sorry for the misunderstanding... –  user14734 Jan 30 '13 at 22:17
    
Closely related: gis.stackexchange.com/a/29893. –  whuber Jan 30 '13 at 22:31
add comment

2 Answers 2

The spatial operation you need is called BUFFER and is implemented in most geographical database managers

share|improve this answer
    
+1 for this answer... although a general question is, why don't you just redraw the polygon to the specifications that you want? –  Andy TIce Jan 31 '13 at 5:03
add comment

if you use geodjango on server side, you can use buffer method in Topological Methods.

polygon.buffer(1000) # 1 km buffer for your polygon

i hope it helps you...

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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