Fix T47370: untranslateable bake panel strings.

Reorder buttons a bit so that these strings are not even needed, makes more
sense to have this grouped anyway.
This commit is contained in:
Brecht Van Lommel 2016-02-09 19:44:15 +01:00
parent 4912e0e746
commit e927f8b424
Notes: blender-bot 2023-02-14 10:21:10 +01:00
Referenced by issue #47370, Some Bake Settings strings not translatable
1 changed files with 37 additions and 46 deletions

View File

@ -1441,7 +1441,43 @@ class CyclesRender_PT_bake(CyclesButtonsPanel, Panel):
col = layout.column()
col.prop(cscene, "bake_type")
col.separator()
col = layout.column()
if cscene.bake_type == 'NORMAL':
col.prop(cbk, "normal_space", text="Space")
row = col.row(align=True)
row.label(text="Swizzle:")
row.prop(cbk, "normal_r", text="")
row.prop(cbk, "normal_g", text="")
row.prop(cbk, "normal_b", text="")
elif cscene.bake_type == 'COMBINED':
row = col.row(align=True)
row.prop(cbk, "use_pass_direct", toggle=True)
row.prop(cbk, "use_pass_indirect", toggle=True)
split = col.split()
split.active = cbk.use_pass_direct or cbk.use_pass_indirect
col = split.column()
col.prop(cbk, "use_pass_diffuse")
col.prop(cbk, "use_pass_glossy")
col.prop(cbk, "use_pass_transmission")
col = split.column()
col.prop(cbk, "use_pass_subsurface")
col.prop(cbk, "use_pass_ambient_occlusion")
col.prop(cbk, "use_pass_emit")
elif cscene.bake_type in {'DIFFUSE', 'GLOSSY', 'TRANSMISSION', 'SUBSURFACE'}:
row = col.row(align=True)
row.prop(cbk, "use_pass_direct", toggle=True)
row.prop(cbk, "use_pass_indirect", toggle=True)
row.prop(cbk, "use_pass_color", toggle=True)
layout.separator()
split = layout.split()
@ -1460,51 +1496,6 @@ class CyclesRender_PT_bake(CyclesButtonsPanel, Panel):
else:
sub.prop(cbk, "cage_extrusion", text="Ray Distance")
if cscene.bake_type == 'NORMAL':
layout.separator()
col = layout.column()
col.label(text="Normal Settings:")
col.prop(cbk, "normal_space", text="Space")
row = col.row(align=True)
row.label(text="Swizzle:")
row.prop(cbk, "normal_r", text="")
row.prop(cbk, "normal_g", text="")
row.prop(cbk, "normal_b", text="")
elif cscene.bake_type == 'COMBINED':
col = layout.column()
col.label(text="Combined Settings:")
row = col.row()
row.prop(cbk, "use_pass_ambient_occlusion")
row.prop(cbk, "use_pass_emit")
row = col.row(align=True)
row.prop(cbk, "use_pass_direct", toggle=True)
row.prop(cbk, "use_pass_indirect", toggle=True)
split = col.split()
split.active = cbk.use_pass_direct or cbk.use_pass_indirect
col = split.column()
col.prop(cbk, "use_pass_diffuse")
col.prop(cbk, "use_pass_glossy")
col = split.column()
col.prop(cbk, "use_pass_transmission")
col.prop(cbk, "use_pass_subsurface")
elif cscene.bake_type in {'DIFFUSE', 'GLOSSY', 'TRANSMISSION', 'SUBSURFACE'}:
layout.separator()
col = layout.column()
col.label(text="{0} Settings:".format(cscene.bake_type.title()))
row = col.row(align=True)
row.prop(cbk, "use_pass_direct", toggle=True)
row.prop(cbk, "use_pass_indirect", toggle=True)
row.prop(cbk, "use_pass_color", toggle=True)
class CyclesRender_PT_debug(CyclesButtonsPanel, Panel):
bl_label = "Debug"