Changeset View
Changeset View
Standalone View
Standalone View
release/scripts/startup/bl_ui/properties_paint_common.py
| Show First 20 Lines • Show All 426 Lines • ▼ Show 20 Lines | def draw(self, context): | ||||
| row = col.row(align=True) | row = col.row(align=True) | ||||
| row.operator("brush.curve_preset", icon='SMOOTHCURVE', text="").shape = 'SMOOTH' | row.operator("brush.curve_preset", icon='SMOOTHCURVE', text="").shape = 'SMOOTH' | ||||
| row.operator("brush.curve_preset", icon='SPHERECURVE', text="").shape = 'ROUND' | row.operator("brush.curve_preset", icon='SPHERECURVE', text="").shape = 'ROUND' | ||||
| row.operator("brush.curve_preset", icon='ROOTCURVE', text="").shape = 'ROOT' | row.operator("brush.curve_preset", icon='ROOTCURVE', text="").shape = 'ROOT' | ||||
| row.operator("brush.curve_preset", icon='SHARPCURVE', text="").shape = 'SHARP' | row.operator("brush.curve_preset", icon='SHARPCURVE', text="").shape = 'SHARP' | ||||
| row.operator("brush.curve_preset", icon='LINCURVE', text="").shape = 'LINE' | row.operator("brush.curve_preset", icon='LINCURVE', text="").shape = 'LINE' | ||||
| row.operator("brush.curve_preset", icon='NOCURVE', text="").shape = 'MAX' | row.operator("brush.curve_preset", icon='NOCURVE', text="").shape = 'MAX' | ||||
| if mode in {'SCULPT', 'PAINT_VERTEX', 'PAINT_WEIGHT'} and brush.sculpt_tool != 'POSE': | if mode in {'SCULPT', 'PAINT_VERTEX', 'PAINT_WEIGHT', 'SCULPT_CURVES'} and brush.sculpt_tool != 'POSE': | ||||
| col.separator() | col.separator() | ||||
| row = col.row(align=True) | row = col.row(align=True) | ||||
| row.use_property_split = True | row.use_property_split = True | ||||
| row.use_property_decorate = False | row.use_property_decorate = False | ||||
| row.prop(brush, "falloff_shape", expand=True) | row.prop(brush, "falloff_shape", expand=True) | ||||
| class DisplayPanel(BrushPanel): | class DisplayPanel(BrushPanel): | ||||
| ▲ Show 20 Lines • Show All 374 Lines • ▼ Show 20 Lines | if mode == 'PAINT_WEIGHT': | ||||
| if brush.weight_tool == 'DRAW': | if brush.weight_tool == 'DRAW': | ||||
| blend_mode = True | blend_mode = True | ||||
| # UV Sculpt # | # UV Sculpt # | ||||
| if mode == 'UV_SCULPT': | if mode == 'UV_SCULPT': | ||||
| size = True | size = True | ||||
| strength = True | strength = True | ||||
| # Sculpt Curves # | |||||
| if mode == 'SCULPT_CURVES': | |||||
| size = True | |||||
| strength = True | |||||
| ### Draw settings. ### | ### Draw settings. ### | ||||
| ups = context.scene.tool_settings.unified_paint_settings | ups = context.scene.tool_settings.unified_paint_settings | ||||
| if blend_mode: | if blend_mode: | ||||
| layout.prop(brush, "blend", text="Blend") | layout.prop(brush, "blend", text="Blend") | ||||
| layout.separator() | layout.separator() | ||||
| if weight: | if weight: | ||||
| ▲ Show 20 Lines • Show All 81 Lines • ▼ Show 20 Lines | if mode == 'SCULPT': | ||||
| # sculpt plane settings | # sculpt plane settings | ||||
| if capabilities.has_sculpt_plane: | if capabilities.has_sculpt_plane: | ||||
| layout.prop(brush, "sculpt_plane") | layout.prop(brush, "sculpt_plane") | ||||
| col = layout.column(heading="Use Original", align=True) | col = layout.column(heading="Use Original", align=True) | ||||
| col.prop(brush, "use_original_normal", text="Normal") | col.prop(brush, "use_original_normal", text="Normal") | ||||
| col.prop(brush, "use_original_plane", text="Plane") | col.prop(brush, "use_original_plane", text="Plane") | ||||
| layout.separator() | layout.separator() | ||||
| elif mode == 'SCULPT_CURVES': | |||||
| if brush.curves_sculpt_tool == 'ADD': | |||||
| layout.prop(brush.curves_sculpt_settings, "add_amount") | |||||
| layout.prop(brush.curves_sculpt_settings, "curve_length") | |||||
| layout.prop(brush.curves_sculpt_settings, "interpolate_length") | |||||
| layout.prop(brush.curves_sculpt_settings, "interpolate_shape") | |||||
| elif brush.curves_sculpt_tool == 'GROW_SHRINK': | |||||
| layout.prop(brush.curves_sculpt_settings, "scale_uniform") | |||||
| layout.prop(brush.curves_sculpt_settings, "minimum_length") | |||||
| # 3D and 2D Texture Paint. | # 3D and 2D Texture Paint. | ||||
| elif mode in {'PAINT_TEXTURE', 'PAINT_2D'}: | elif mode in {'PAINT_TEXTURE', 'PAINT_2D'}: | ||||
| capabilities = brush.image_paint_capabilities | capabilities = brush.image_paint_capabilities | ||||
| use_accumulate = capabilities.has_accumulate | use_accumulate = capabilities.has_accumulate | ||||
| if mode == 'PAINT_2D': | if mode == 'PAINT_2D': | ||||
| layout.prop(brush, "use_paint_antialiasing") | layout.prop(brush, "use_paint_antialiasing") | ||||
| else: | else: | ||||
| ▲ Show 20 Lines • Show All 421 Lines • Show Last 20 Lines | |||||