[OSM-dev] Lightweight editor idea

Nick Whitelegg nick at hogweed.org
Mon Nov 5 08:49:58 GMT 2007


Hello everyone,

Have been thinking of the concept of a very lightweight editor where people 
literally just draw on the rendered maps (using the OpenLayers drawing tool) 
for a while. The server would then do all the checks for conflicts, etc, 
behind the scenes.

The thing I would have in mind would run locally on the Freemap server, modify 
the PostGIS database on Freemap but also at the same time modify OSM 
(checking for conflicts as it does). Something like (in pseudocode):

New way (drawn using OpenLayers) read in from user
Using a distance checking algorithm, we check with OSM to make sure that the 
way has not been added already (i.e. since the last planet dump)
If way not added
	Loop through each point in the newly drawn way
	If point is near an existing node
		Add existing node to new way
	else
		Create new node and add to new way
		If point is within a certain distance of an existing way
			Split existing way
		end if
	end if
end if
		
Changes would be made to the local database as well as the main OSM server.

Has anyone else thought of this sort of thing? I like the idea of "specialist" 
sites like Freemap being able to create their own lightweight editors but 
there needs to be some way of syncing with the main OSM server as they will 
be running off planet and so will be up to a week out of date.

Nick




More information about the dev mailing list