http://fmtyewtk.blogspot.com/2009/09/just-create-lots-of-meshes.html I got the first version of the openstreetmap to blender export running! w0000000t!
using blender 2.49 on ubuntu gnu linux.
IT WORKS!!!!
here is the solution :
def create_LINE(BROKEN_LINE,tv):
global TAG4,nedge
for bl in BROKEN_LINE:
sc = Blender.Scene.GetCurrent()
me = Blender.Mesh.New('myMesh')
print "Create LINE "
print BROKEN_LINE
print "tv "
print tv
print "Version %d" % BLversion
ob = Blender.Object.New('Mesh')
ob.link(me)
sc.link(ob)
ob.setDrawMode(32)
ob.setDrawType(2)
v=me.verts
e=me.edges
for bl2 in bl:
me.verts.extend(bl2[0],bl2[1],bl2[2])
v = me.verts
if len(v) >= 2:
e.extend(v[-2],v[-1])
#if tv :
me.sel=1
me.remDoubles(0.0001)
CODE:
http://bazaar.launchpad.net/~kosova/+junk/openstreetmapkosova/revision/67
Discussion