ply export patch 5576 applied with parts rewritten.

BPyMesh getMeshFromObject bugfix in some cases non mesh object types could be a problem.
This commit is contained in:
2007-01-09 16:01:38 +00:00
parent a18275c818
commit e2da632f8f
2 changed files with 141 additions and 68 deletions

View File

@@ -408,11 +408,9 @@ def getMeshFromObject(ob, container_mesh=None, apply_modifiers=True, vgroups=Tru
Dont apply modifiers, copy the mesh.
So we can transform the data. its easiest just to get a copy of the mesh.
'''
tempob= Blender.Object.New('Mesh')
tempob.shareFrom(ob)
scn.link(tempob)
tempob= scn.objects.new(ob.getData(mesh=1))
mesh.getFromObject(tempob)
scn.unlink(tempob)
scn.objects.unlink(tempob)
if type == 'Mesh':
if vgroups: