Brushstroke Tools: Initial Version #328

Merged
Simon Thommes merged 229 commits from SimonThommes/blender-studio-tools:brushstroke_tools-initial-version into main 2024-11-06 15:03:47 +01:00
Showing only changes of commit 5fad5d7c69 - Show all commits

View File

@ -133,13 +133,14 @@ def draw_material_settings(layout, material):
layout.prop(material.node_tree.nodes['Principled BSDF'].inputs[1], 'default_value', text='Metallic')
layout.prop(material.node_tree.nodes['Principled BSDF'].inputs[2], 'default_value', text='Roughness')
layout.prop(material.node_tree.nodes['Bump'], 'mute', text='Bump', invert_checkbox=True)
layout.prop(material.node_tree.nodes['Bump'].inputs[0], 'default_value', text='Bump Strength')
row = layout.row()
if material.node_tree.nodes['Bump'].mute:
row.active = False
row.prop(material.node_tree.nodes['Bump'].inputs[0], 'default_value', text='Bump Strength')
brush_header, brush_panel = layout.panel('brush_panel', default_closed = True)
brush_header.label(text='Brush Style', icon='BRUSHES_ALL')
if brush_panel:
#brush_panel.prop_search(material.node_tree.nodes['Brush Style'], 'node_tree', settings, 'styles', icon='BRUSHES_ALL')
#brush_panel.template_node_inputs(material.node_tree.nodes['Brush Style'])
brush_panel.prop(material, 'brush_style')
brush_panel.template_node_inputs(material.node_tree.nodes['Brush Curve'])
@ -161,6 +162,8 @@ def draw_effect_panel_recursive(effects_panel, material, prev_node):
header.prop(node, 'mute', invert_checkbox=True, icon_only=True)
header.label(text=node.label if node.label else node.name)
if panel:
if node.mute:
panel.active = False
for input in node.inputs[1:]:
panel.prop(input, 'default_value', text=input.name)