__author__ = 'thoth'
# http://blender.stackexchange.com/questions/32546/how-do-i-name-a-mesh-using-python-when-i-dont-know-its-present-name
import bpy
scn = bpy.context.scene
names = [ obj.name for obj in scn.objects]
bpy.ops.mesh.separate(type="SELECTED")
new_objs = [ obj for obj in scn.objects if not obj.name in names]
print( [ obj.name for obj in new_objs ] )
|
Blender python API quick-start
Syntax highlighting by Pygments.