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 204d07a201 - Show all commits

View File

@ -751,7 +751,7 @@ class BSBST_OT_render_setup(bpy.types.Operator):
]
)
trans_pass_toggle: bpy.props.BoolProperty(default=True)
trans_pass: bpy.props.IntProperty(default=256)
trans_pass: bpy.props.IntProperty(name='Transparency Passes', default=256, min=0, soft_max=1024)
prop_map = {
'CYCLES':['trans_pass',
@ -762,12 +762,16 @@ class BSBST_OT_render_setup(bpy.types.Operator):
def draw(self, context):
layout = self.layout
if self.render_engine == 'ALL':
props = [*v for k, v in self.prop_map]
else:
props = self.prop_map[self.render_engine]
print(props)
layout.prop(self, 'render_engine')
layout.prop(self, 'render_engine', text='')
for k, v in self.prop_map.items():
if self.render_engine not in [k, 'ALL']:
continue
layout.label(text=k.capitalize())
for prop in v:
split = layout.split(factor=.1)
split.prop(self, f'{prop}_toggle', icon_only=True)
split.active = getattr(self, f'{prop}_toggle', False)
split.prop(self, prop)
def execute(self, context):
settings = context.scene.BSBST_settings