Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPablo Dobarro <pablodp606@gmail.com>2020-06-01 23:36:26 +0300
committerPablo Dobarro <pablodp606@gmail.com>2020-06-01 23:37:06 +0300
commit1d4bae856690c7a4603789509a5842dd6b5f8be1 (patch)
tree6be194b9c0c4282a0ed7528f2a9b07ba51cbe4d4 /release
parent3778f168f688a6c76f5c0b54262b1ed82deb0c84 (diff)
Sculpt: Cloth Filter
This tool is similar to the cloth brush, but it applies the cloth simulation deformation to the whole mesh in an uniform way. The simulation can be controlled using the mask to pin vertices and the face sets to define force action areas. It uses the same solver as the cloth brush which now no longer depends on StrokeCache. Reviewed By: sergey Differential Revision: https://developer.blender.org/D7857
Diffstat (limited to 'release')
-rw-r--r--release/scripts/presets/keyconfig/keymap_data/blender_default.py11
-rw-r--r--release/scripts/startup/bl_ui/space_toolsystem_toolbar.py20
2 files changed, 31 insertions, 0 deletions
diff --git a/release/scripts/presets/keyconfig/keymap_data/blender_default.py b/release/scripts/presets/keyconfig/keymap_data/blender_default.py
index 0db7b79d8c9..08e81d89c4f 100644
--- a/release/scripts/presets/keyconfig/keymap_data/blender_default.py
+++ b/release/scripts/presets/keyconfig/keymap_data/blender_default.py
@@ -6272,6 +6272,16 @@ def km_3d_view_tool_sculpt_mesh_filter(params):
]},
)
+def km_3d_view_tool_sculpt_cloth_filter(params):
+ return (
+ "3D View Tool: Sculpt, Cloth Filter",
+ {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
+ {"items": [
+ ("sculpt.cloth_filter", {"type": params.tool_tweak, "value": 'ANY'},
+ None)
+ ]},
+ )
+
def km_3d_view_tool_paint_weight_sample_weight(params):
return (
"3D View Tool: Paint Weight, Sample Weight",
@@ -6811,6 +6821,7 @@ def generate_keymaps(params=None):
km_3d_view_tool_sculpt_box_mask(params),
km_3d_view_tool_sculpt_lasso_mask(params),
km_3d_view_tool_sculpt_mesh_filter(params),
+ km_3d_view_tool_sculpt_cloth_filter(params),
km_3d_view_tool_paint_weight_sample_weight(params),
km_3d_view_tool_paint_weight_sample_vertex_group(params),
km_3d_view_tool_paint_weight_gradient(params),
diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
index 1aa5dde168b..b4c1ea5163f 100644
--- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
+++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py
@@ -1228,6 +1228,25 @@ class _defs_sculpt:
draw_settings=draw_settings,
)
+ @ToolDef.from_fn
+ def cloth_filter():
+ def draw_settings(_context, layout, tool):
+ props = tool.operator_properties("sculpt.cloth_filter")
+ layout.prop(props, "type", expand=False)
+ layout.prop(props, "strength")
+ layout.prop(props, "cloth_mass")
+ layout.prop(props, "cloth_damping")
+ layout.prop(props, "use_face_sets")
+
+ return dict(
+ idname="builtin.cloth_filter",
+ label="Cloth Filter",
+ icon="ops.sculpt.cloth_filter",
+ widget=None,
+ keymap=(),
+ draw_settings=draw_settings,
+ )
+
class _defs_vertex_paint:
@@ -2402,6 +2421,7 @@ class VIEW3D_PT_tools_active(ToolSelectPanelHelper, Panel):
_defs_sculpt.hide_border,
None,
_defs_sculpt.mesh_filter,
+ _defs_sculpt.cloth_filter,
None,
_defs_transform.translate,
_defs_transform.rotate,