[Bf-blender-cvs] [6f5535e56ca] sculpt-dev: Merge branch 'master' into sculpt-dev

Joseph Eagar noreply at git.blender.org
Sat Apr 9 06:40:37 CEST 2022


Commit: 6f5535e56ca067c5c2a9c16945b9b62e6687149d
Author: Joseph Eagar
Date:   Fri Apr 8 17:27:29 2022 -0700
Branches: sculpt-dev
https://developer.blender.org/rB6f5535e56ca067c5c2a9c16945b9b62e6687149d

Merge branch 'master' into sculpt-dev

===================================================================



===================================================================

diff --cc release/datafiles/locale
index 2d12637a69d,716dc02ec30..63699f96834
--- a/release/datafiles/locale
+++ b/release/datafiles/locale
@@@ -1,1 -1,1 +1,1 @@@
- Subproject commit 2d12637a69df7643484a8a3655b7eeb6faa170a7
 -Subproject commit 716dc02ec30c0810513f7b4adc4ae865ae50c4e6
++Subproject commit 63699f968344db7dc853d2c5972325beea44900c
diff --cc release/scripts/addons
index c34f0b90d49,787ea78f7fa..baa581415c7
--- a/release/scripts/addons
+++ b/release/scripts/addons
@@@ -1,1 -1,1 +1,1 @@@
- Subproject commit c34f0b90d49938eccf9c1a9ae59b055155e00f9b
 -Subproject commit 787ea78f7fa6f0373d80ba1247768402df93f8ad
++Subproject commit baa581415c7ed23d7c45ef873631748135672683
diff --cc release/scripts/presets/keyconfig/keymap_data/blender_default.py
index 5be16e047d2,a1913945364..a1ba04049dd
--- a/release/scripts/presets/keyconfig/keymap_data/blender_default.py
+++ b/release/scripts/presets/keyconfig/keymap_data/blender_default.py
@@@ -5619,11 -6215,32 +5678,30 @@@ def km_sculpt_expand_modal(_params)
      return keymap
  
  
+ def km_curve_pen_modal_map(_params):
+     items = []
+     keymap = (
+         "Curve Pen Modal Map",
+         {"space_type": 'EMPTY', "region_type": 'WINDOW', "modal": True},
+         {"items": items},
+     )
+ 
+     items.extend([
+         ("FREE_ALIGN_TOGGLE", {"type": 'LEFT_SHIFT', "value": 'ANY', "any": True}, None),
+         ("MOVE_ADJACENT", {"type": 'LEFT_CTRL', "value": 'ANY', "any": True}, None),
+         ("MOVE_ENTIRE", {"type": 'SPACE', "value": 'ANY', "any": True}, None),
+         ("LOCK_ANGLE", {"type": 'LEFT_ALT', "value": 'ANY', "any": True}, None),
+         ("LINK_HANDLES", {"type": 'RIGHT_CTRL', "value": 'PRESS', "any": True}, None),
+     ])
+ 
+     return keymap
+ 
+ 
  # Fallback for gizmos that don't have custom a custom key-map.
  def km_generic_gizmo(_params):
 -    keymap = (
 -        "Generic Gizmo",
 +    keymap = ("Generic Gizmo",
          {"space_type": 'EMPTY', "region_type": 'WINDOW'},
 -        {"items": _template_items_gizmo_tweak_value()},
 -    )
 +        {"items": _template_items_gizmo_tweak_value()},)
  
      return keymap
  
@@@ -6292,18 -7143,47 +6370,39 @@@ def km_3d_view_tool_edit_mesh_rip_edge(
  # Tool System (3D View, Edit Curve)
  
  def km_3d_view_tool_edit_curve_draw(params):
 -    return (
 -        "3D View Tool: Edit Curve, Draw",
 +    return ("3D View Tool: Edit Curve, Draw",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
 -        {"items": [
 -            # No need for `tool_modifier` since this takes all input.
 +        {"items": [# No need for `tool_modifier` since this takes all input.
              ("curve.draw", {"type": params.tool_mouse, "value": 'PRESS'},
 -             {"properties": [("wait_for_input", False)]}),
 -        ]},
 -    )
 +             {"properties": [("wait_for_input", False)]}),]},)
  
  
+ def km_3d_view_tool_edit_curve_pen(params):
+     return (
+         "3D View Tool: Edit Curve, Curve Pen",
+         {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
+         {"items": [
+             ("curve.pen", {"type": params.tool_mouse, "value": 'PRESS'},
+              {"properties": [
+                  ("extrude_point", True),
+                  ("move_segment", True),
+                  ("select_point", True),
+                  ("move_point", True),
+                  ("close_spline_method", "ON_CLICK"),
+              ]}),
+             ("curve.pen", {"type": params.tool_mouse, "value": 'PRESS', "ctrl": True},
+              {"properties": [("insert_point", True), ("delete_point", True)]}),
+             ("curve.pen", {"type": params.tool_mouse, "value": 'DOUBLE_CLICK'},
+              {"properties": [("toggle_vector", True), ("cycle_handle_type", True),]}),
+         ]},
+     )
+ 
+ 
  def km_3d_view_tool_edit_curve_tilt(params):
 -    return (
 -        "3D View Tool: Edit Curve, Tilt",
 +    return ("3D View Tool: Edit Curve, Tilt",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
 -        {"items": [
 -            ("transform.tilt", {**params.tool_maybe_tweak_event, **params.tool_modifier},
 -             {"properties": [("release_confirm", True)]}),
 -        ]},
 -    )
 +        {"items": [("transform.tilt", {**params.tool_maybe_tweak_event, **params.tool_modifier},
 +             {"properties": [("release_confirm", True)]}),]},)
  
  
  def km_3d_view_tool_edit_curve_radius(params):
@@@ -6446,20 -7348,33 +6545,22 @@@ def km_3d_view_tool_sculpt_ipmask_filte
  
  
  def km_3d_view_tool_sculpt_cloth_filter(params):
 -    return (
 -        "3D View Tool: Sculpt, Cloth Filter",
 +    return ("3D View Tool: Sculpt, Cloth Filter",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
 -        {"items": [
 -            ("sculpt.cloth_filter", params.tool_maybe_tweak_event, None)
 -        ]},
 -    )
 -
 +        {"items": [("sculpt.cloth_filter", params.tool_maybe_tweak_event, None)]},)
  
  def km_3d_view_tool_sculpt_color_filter(params):
 -    return (
 -        "3D View Tool: Sculpt, Color Filter",
 +    return ("3D View Tool: Sculpt, Color Filter",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
 -        {"items": [
 -            ("sculpt.color_filter", params.tool_maybe_tweak_event, None)
 -        ]},
 -    )
 -
 +        {"items": [("sculpt.color_filter", params.tool_maybe_tweak_event, None)]},)
  
  def km_3d_view_tool_sculpt_mask_by_color(params):
 -    return (
 -        "3D View Tool: Sculpt, Mask by Color",
 +    return ("3D View Tool: Sculpt, Mask by Color",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
-         {"items": [("sculpt.mask_by_color", {"type": params.tool_mouse, "value": 'ANY'}, None),
-             ("sculpt.mask_by_color", params.tool_tweak_event, None),]},)
+         {"items": [
+             ("sculpt.mask_by_color", {"type": params.tool_mouse, "value": 'CLICK'}, None)
+         ]},
+     )
  
  
  def km_3d_view_tool_sculpt_face_set_edit(params):
@@@ -6714,9 -7701,10 +6815,9 @@@ def km_3d_view_tool_edit_gpencil_interp
  # Tool System (3D View, Grease Pencil, Sculpt)
  
  def km_3d_view_tool_sculpt_gpencil_select(params):
 -    return (
 -        "3D View Tool: Sculpt Gpencil, Tweak",
 +    return ("3D View Tool: Sculpt Gpencil, Tweak",
          {"space_type": 'VIEW_3D', "region_type": 'WINDOW'},
-         {"items": _template_items_tool_select(params, "gpencil.select", "view3d.cursor3d", False)},
+         {"items": _template_items_tool_select(params, "gpencil.select", "view3d.cursor3d")},
      )
  
  
diff --cc release/scripts/startup/bl_ui/properties_data_mesh.py
index 86a3576458c,1bfd82cc790..7dc73499dde
--- a/release/scripts/startup/bl_ui/properties_data_mesh.py
+++ b/release/scripts/startup/bl_ui/properties_data_mesh.py
@@@ -425,113 -419,6 +410,7 @@@ class DATA_PT_uv_texture(MeshButtonsPan
          col.operator("mesh.uv_texture_add", icon='ADD', text="")
          col.operator("mesh.uv_texture_remove", icon='REMOVE', text="")
  
- class MESH_UL_color_attributes(UIList):
-     display_domain_names = {
-         'POINT': "Vertex",
-         'EDGE': "Edge",
-         'FACE': "Face",
-         'CORNER': "Face Corner",
-     }
- 
-     def filter_items(self, context, data, property):
-         attrs = getattr(data, property)
-         ret = []
-         idxs = []
-         idx = 0
- 
-         for item in attrs:
-             bad = item.domain not in ["POINT", "CORNER"]
-             bad = bad or item.data_type not in ["FLOAT_COLOR", "BYTE_COLOR"]
-             bad = bad or item.temporary
- 
-             #if not bad:
-             #print(bad, idx, item.name, item.domain, item.data_type)
- 
-             ret.append(self.bitflag_filter_item if not bad else 0)
-             idxs.append(idx)
- 
-             # note this is index in full attribute list, not color list
-             idx += 1
- 
-         return ret, idxs
- 
-     def draw_item(self, _context, layout, _data, attribute, _icon, _active_data, _active_propname, _index):
-         data_type = attribute.bl_rna.properties['data_type'].enum_items[attribute.data_type]
- 
-         domain_name = self.display_domain_names.get(attribute.domain, "")
- 
-         split = layout.split(factor=0.50)
-         split.emboss = 'NONE'
-         split.prop(attribute, "name", text="")
- 
-         split.prop(attribute, "active_render", text="", icon = 'RESTRICT_RENDER_OFF' if attribute.active_render else 'RESTRICT_RENDER_ON')
- 
-         sub = split.row()
-         sub.alignment = 'RIGHT'
-         sub.active = False
-         sub.label(text="%s ▶ %s" % (domain_name, data_type.name))
- 
- 
- class DATA_PT_vertex_colors(MeshButtonsPanel, Panel):
-     bl_label = "Color Attributes"
-     bl_options = {'DEFAULT_CLOSED'}
-     COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE', 'BLENDER_WORKBENCH'}
- 
-     def draw(self, context):
-         mesh = context.mesh
- 
-         layout = self.layout
-         row = layout.row()
- 
-         col = row.column()
-         col.template_list("MESH_UL_color_attributes",
-             "attributes",
-             mesh,
-             "attributes",
-             mesh.attributes,
-             "active_color_index",
-             rows=3,)
- 
-         col = row.column(align=True)
-         col.operator("geometry.color_attribute_add", icon='ADD', text="")
-         col.operator("geometry.color_attribute_remove", icon='REMOVE', text="")
- 
-         #active = mesh.attributes.active
-         #if active and (active.domain == "POINT" and active.data_type == "FLOAT_COLOR"):
-         #    layout.operator("sculpt.vertex_to_loop_colors", text="Save To Corners")
-         #    layout.operator("sculpt.loop_to_vertex_colors", text="Load From Corners")
- 
-         self.draw_attribute_warnings(context, layout)
- 
-     def draw_attribute_warnings(self, context, layout):
-         attributes_by_name = defaultdict(list)
- 
-         ob = context.object
-         mesh = ob.data
- 
-         builtin_attribute = object()
- 
-         def add_builtin(name):
-             attributes_by_name[name].append(builtin_attribute)
- 
-         def add_attributes(layers):
-             for layer in layers:
-                 attributes_by_name[layer.name].append(layer)
- 
-   

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list