use static sets rather then tuples, python optimizes this case.

minor change to lightmap unpack collecting unique meshes.
This commit is contained in:
Campbell Barton
2011-08-08 05:21:37 +00:00
parent 0160901c90
commit 22d2764d50
12 changed files with 20 additions and 20 deletions

View File

@@ -520,7 +520,7 @@ def unwrap(operator, context, **kwargs):
if obj and obj.type == 'MESH':
meshes = [obj.data]
else:
meshes = {me.name: me for obj in context.selected_objects if obj.type == 'MESH' for me in (obj.data,) if not me.library if len(me.faces)}.values()
meshes = list({me for obj in context.selected_objects if obj.type == 'MESH' for me in (obj.data,) if me.faces and me.library is None})
if not meshes:
operator.report({'ERROR'}, "No mesh object.")