def main(self, context, chboxaxisx, chboxaxisy,chboxaxisz, distance):
distancia = distance
obj = bpy.context.object
me = obj.data
bm = bmesh.from_edit_mesh(me)
if chboxaxisx:
x = distancia
else:
x = 0.0
if chboxaxisy:
y = distancia
else:
y = 0.0
if chboxaxisz:
z = distancia
else:
z = 0.0
vertices = [v for v in bm.verts if (v.select and not v.hide)]
bmesh.ops.translate(
bm,
verts=vertices,
vec=(x, y, z))
### separar caras###
bmesh.update_edit_mesh(me, True)
#"Render"
bpy.ops.render.render()
评论列表
文章目录