Normal UI: Remove normals toolbar and add/muliply menu options.
See T64324 for discussion re improving normal editing ui. As next step, remove the face_strength tool settings because menu operator now includes that. Move face_strenth enum to better place. Remove normals toolbar panel because only thing left (normal_vector) can stay hidden for copy/paste. Remove add vector and multiply vector menu entries as they are useless without ui method for specifying operand, and they are very low utility operations anyway.
This commit is contained in:
parent
49f530c7da
commit
43500671dc
|
@ -3819,8 +3819,6 @@ class VIEW3D_MT_edit_mesh_normals(Menu):
|
|||
|
||||
layout.operator("mesh.normals_tools", text="Copy Vectors").mode = 'COPY'
|
||||
layout.operator("mesh.normals_tools", text="Paste Vectors").mode = 'PASTE'
|
||||
layout.operator("mesh.normals_tools", text="Add Vectors").mode = 'ADD'
|
||||
layout.operator("mesh.normals_tools", text="Multiply Vectors").mode = 'MULTIPLY'
|
||||
|
||||
layout.operator("mesh.smoothen_normals", text="Smoothen Vectors")
|
||||
layout.operator("mesh.normals_tools", text="Reset Vectors").mode = 'RESET'
|
||||
|
|
|
@ -1621,22 +1621,6 @@ class VIEW3D_PT_tools_particlemode_options_display(View3DPanel, Panel):
|
|||
sub.prop(pe, "fade_frames", slider=True)
|
||||
|
||||
|
||||
class VIEW3D_PT_tools_meshedit_normal(View3DPanel, Panel):
|
||||
bl_category = "Tool"
|
||||
bl_context = ".mesh_edit"
|
||||
bl_label = "Normals"
|
||||
bl_options = {'DEFAULT_CLOSED'}
|
||||
|
||||
def draw(self, context):
|
||||
layout = self.layout
|
||||
layout.use_property_split = True
|
||||
layout.use_property_decorate = False # No animation.
|
||||
|
||||
tool_settings = context.tool_settings
|
||||
|
||||
layout.prop(tool_settings, "normal_vector", text="Normal Vector")
|
||||
layout.prop(tool_settings, "face_strength", text="Face Strength")
|
||||
|
||||
# ********** grease pencil object tool panels ****************
|
||||
|
||||
# Grease Pencil drawing brushes
|
||||
|
@ -2044,7 +2028,6 @@ class VIEW3D_PT_gpencil_brush_presets(PresetPanel, Panel):
|
|||
|
||||
|
||||
classes = (
|
||||
VIEW3D_PT_tools_meshedit_normal,
|
||||
VIEW3D_PT_tools_meshedit_options,
|
||||
VIEW3D_PT_tools_curveedit_options_stroke,
|
||||
VIEW3D_PT_tools_armatureedit_options,
|
||||
|
|
|
@ -126,6 +126,13 @@ enum {
|
|||
BEVEL_MITER_ARC,
|
||||
};
|
||||
|
||||
/* Normal Face Strength values */
|
||||
enum {
|
||||
FACE_STRENGTH_WEAK = -16384,
|
||||
FACE_STRENGTH_MEDIUM = 0,
|
||||
FACE_STRENGTH_STRONG = 16384,
|
||||
};
|
||||
|
||||
extern const BMOpDefine *bmo_opdefines[];
|
||||
extern const int bmo_opdefines_total;
|
||||
|
||||
|
|
|
@ -1499,7 +1499,7 @@ typedef struct ToolSettings {
|
|||
|
||||
/* Normal Editing */
|
||||
float normal_vector[3];
|
||||
int face_strength;
|
||||
char _pad6[4];
|
||||
} ToolSettings;
|
||||
|
||||
/* *************************************************************** */
|
||||
|
@ -2089,13 +2089,6 @@ enum {
|
|||
OB_DRAW_GROUPUSER_ALL = 2,
|
||||
};
|
||||
|
||||
/* toolsettings->face_strength */
|
||||
enum {
|
||||
FACE_STRENGTH_WEAK = -16384,
|
||||
FACE_STRENGTH_MEDIUM = 0,
|
||||
FACE_STRENGTH_STRONG = 16384,
|
||||
};
|
||||
|
||||
/* object_vgroup.c */
|
||||
/* ToolSettings.vgroupsubset */
|
||||
typedef enum eVGroupSelect {
|
||||
|
|
|
@ -3167,10 +3167,6 @@ static void rna_def_tool_settings(BlenderRNA *brna)
|
|||
RNA_def_property_ui_text(prop, "Normal Vector", "Normal Vector used to copy, add or multiply");
|
||||
RNA_def_property_ui_range(prop, -10000.0, 10000.0, 1, 3);
|
||||
|
||||
prop = RNA_def_property(srna, "face_strength", PROP_ENUM, PROP_NONE);
|
||||
RNA_def_property_enum_items(prop, mod_weighted_strength);
|
||||
RNA_def_property_ui_text(prop, "Face Strength", "Set strength of face to specified value");
|
||||
|
||||
/* Unified Paint Settings */
|
||||
prop = RNA_def_property(srna, "unified_paint_settings", PROP_POINTER, PROP_NONE);
|
||||
RNA_def_property_flag(prop, PROP_NEVER_NULL);
|
||||
|
|
|
@ -35,6 +35,8 @@
|
|||
#include "MOD_modifiertypes.h"
|
||||
#include "MOD_util.h"
|
||||
|
||||
#include "bmesh.h"
|
||||
|
||||
#define CLNORS_VALID_VEC_LEN (1e-6f)
|
||||
|
||||
typedef struct ModePair {
|
||||
|
|
Loading…
Reference in New Issue