[Blender] Доработаны процедуры ретопологии мешей

This commit is contained in:
brothermechanic 2023-05-19 18:35:03 +00:00 committed by Igor Brylyov
parent 45e0d29ea0
commit 6560a4359d
9 changed files with 188 additions and 204 deletions

View file

@ -43,7 +43,7 @@ def asset_setup(transforms=True, sharpness=True, shading=True):
bpy.ops.object.mode_set(mode='EDIT')
bpy.ops.mesh.select_all(action='DESELECT')
bpy.ops.mesh.select_mode(type='EDGE')
bpy.ops.mesh.edges_select_sharp( sharpness = math.radians(30) )
bpy.ops.mesh.edges_select_sharp( sharpness = math.radians(10) )
bpy.ops.mesh.mark_sharp()
bpy.ops.mesh.select_all(action='SELECT')
bpy.ops.uv.smart_project()
@ -57,9 +57,6 @@ def asset_setup(transforms=True, sharpness=True, shading=True):
bpy.context.view_layer.objects.active.modifiers["decimate"].decimate_type = "DISSOLVE"
bpy.context.view_layer.objects.active.modifiers["decimate"].angle_limit = 0.00872665
bpy.context.object.modifiers["decimate"].show_expanded = 0
bpy.context.view_layer.objects.active.modifiers.new(type='WEIGHTED_NORMAL', name='weightednormal')
bpy.context.view_layer.objects.active.modifiers["weightednormal"].keep_sharp = 1
bpy.context.object.modifiers["weightednormal"].show_expanded = 0
bpy.context.view_layer.objects.active.modifiers.new(type='TRIANGULATE', name='triangulate')
bpy.context.object.modifiers["triangulate"].keep_custom_normals = 1
bpy.context.object.modifiers["triangulate"].show_expanded = 0