diff options
-rw-r--r-- | intern/cycles/blender/addon/ui.py | 384 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/properties_object.py | 185 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/properties_render.py | 159 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/properties_scene.py | 116 |
4 files changed, 420 insertions, 424 deletions
diff --git a/intern/cycles/blender/addon/ui.py b/intern/cycles/blender/addon/ui.py index 2900f47c7bd..db59063ade2 100644 --- a/intern/cycles/blender/addon/ui.py +++ b/intern/cycles/blender/addon/ui.py @@ -20,10 +20,10 @@ import bpy from bpy_extras.node_utils import find_node_input, find_output_node from bpy.types import ( - Panel, - Menu, - Operator, - ) + Panel, + Menu, + Operator, +) class CYCLES_MT_sampling_presets(Menu): @@ -86,6 +86,7 @@ def use_sample_all_lights(context): return cscene.sample_all_lights_direct or cscene.sample_all_lights_indirect + def show_device_active(context): cscene = context.scene.cycles if cscene.device != 'GPU': @@ -145,6 +146,7 @@ class CYCLES_RENDER_PT_sampling(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = False scene = context.scene cscene = scene.cycles @@ -154,56 +156,52 @@ class CYCLES_RENDER_PT_sampling(CyclesButtonsPanel, Panel): row.operator("render.cycles_sampling_preset_add", text="", icon="ZOOMIN") row.operator("render.cycles_sampling_preset_add", text="", icon="ZOOMOUT").remove_active = True - row = layout.row() - sub = row.row() - sub.prop(cscene, "progressive", text="") - row.prop(cscene, "use_square_samples") - - split = layout.split() - - col = split.column() - sub = col.column(align=True) - sub.label("Settings:") - - seed_sub = sub.row(align=True) - seed_sub.prop(cscene, "seed") - seed_sub.prop(cscene, "use_animated_seed", text="", icon="TIME") + layout.use_property_split = True - sub.prop(cscene, "sample_clamp_direct") - sub.prop(cscene, "sample_clamp_indirect") - sub.prop(cscene, "light_sampling_threshold") + layout.prop(cscene, "progressive") if cscene.progressive == 'PATH' or use_branched_path(context) is False: - col = split.column() - sub = col.column(align=True) - sub.label(text="Samples:") - sub.prop(cscene, "samples", text="Render") - sub.prop(cscene, "preview_samples", text="Preview") + col = layout.column(align=True) + col.prop(cscene, "samples", text="Render Samples") + col.prop(cscene, "preview_samples", text="Preview Samples") + col.prop(cscene, "use_square_samples") # Duplicate below. else: - sub.label(text="AA Samples:") - sub.prop(cscene, "aa_samples", text="Render") - sub.prop(cscene, "preview_aa_samples", text="Preview") + col = layout.column(align=True) + col.prop(cscene, "aa_samples", text="Render Samples") + col.prop(cscene, "preview_aa_samples", text="Preview Samples") - col = split.column() - sub = col.column(align=True) - sub.label(text="Samples:") - sub.prop(cscene, "diffuse_samples", text="Diffuse") - sub.prop(cscene, "glossy_samples", text="Glossy") - sub.prop(cscene, "transmission_samples", text="Transmission") - sub.prop(cscene, "ao_samples", text="AO") + col = layout.column(align=True) + col.prop(cscene, "diffuse_samples", text="Diffuse Samples") + col.prop(cscene, "glossy_samples", text="Glossy Samples") + col.prop(cscene, "transmission_samples", text="Transmission Samples") + col.prop(cscene, "ao_samples", text="AO Samples") - subsub = sub.row(align=True) - subsub.active = use_sample_all_lights(context) - subsub.prop(cscene, "mesh_light_samples", text="Mesh Light") + sub = col.row(align=True) + sub.active = use_sample_all_lights(context) + sub.prop(cscene, "mesh_light_samples", text="Mesh Light Samples") - sub.prop(cscene, "subsurface_samples", text="Subsurface") - sub.prop(cscene, "volume_samples", text="Volume") + col.prop(cscene, "subsurface_samples", text="Subsurface Samples") + col.prop(cscene, "volume_samples", text="Volume Samples") + + col.prop(cscene, "use_square_samples") # Duplicate above. col = layout.column(align=True) col.prop(cscene, "sample_all_lights_direct") col.prop(cscene, "sample_all_lights_indirect") + col = layout.column(align=True) + col.prop(cscene, "light_sampling_threshold", text="Light Threshold") + + col = layout.column(align=True) + col.prop(cscene, "sample_clamp_direct") + col.prop(cscene, "sample_clamp_indirect") + + row = layout.row(align=True) + row.prop(cscene, "seed") + row.prop(cscene, "use_animated_seed", text="", icon="TIME") + layout.row().prop(cscene, "sampling_pattern", text="Pattern") + draw_samples_info(layout, context) @@ -213,56 +211,48 @@ class CYCLES_RENDER_PT_geometry(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene cscene = scene.cycles ccscene = scene.cycles_curves - row = layout.row() - row.label("Volume Sampling:") - row = layout.row() - row.prop(cscene, "volume_step_size") - row.prop(cscene, "volume_max_steps") + col = layout.column(align=True) + col.prop(cscene, "volume_step_size", text="Volume Step Size") + col.prop(cscene, "volume_max_steps", text="Volume Max Steps") - layout.separator() + col.separator() if cscene.feature_set == 'EXPERIMENTAL': - layout.label("Subdivision Rate:") - split = layout.split() - col = split.column() + col = layout.column() sub = col.column(align=True) - sub.prop(cscene, "dicing_rate", text="Render") - sub.prop(cscene, "preview_dicing_rate", text="Preview") + sub.prop(cscene, "dicing_rate", text="Dicing Rate Render") + sub.prop(cscene, "preview_dicing_rate", text="Dicing Rate Preview") - col = split.column() col.prop(cscene, "offscreen_dicing_scale", text="Offscreen Scale") col.prop(cscene, "max_subdivisions") - layout.prop(cscene, "dicing_camera") + col.prop(cscene, "dicing_camera") - layout.separator() + col.separator() - layout.label("Hair:") - layout.prop(ccscene, "use_curves", text="Use Hair") + layout.prop(ccscene, "use_curves", text="Hair Rendering") col = layout.column() col.active = ccscene.use_curves - col.prop(ccscene, "primitive", text="Primitive") + col.prop(ccscene, "minimum_width", text="Min Pixels") + col.prop(ccscene, "maximum_width", text="Max Extension") col.prop(ccscene, "shape", text="Shape") - if not (ccscene.primitive in {'CURVE_SEGMENTS', 'LINE_SEGMENTS'} and ccscene.shape == 'RIBBONS'): col.prop(ccscene, "cull_backfacing", text="Cull back-faces") + col.prop(ccscene, "primitive", text="Primitive") if ccscene.primitive == 'TRIANGLES' and ccscene.shape == 'THICK': col.prop(ccscene, "resolution", text="Resolution") elif ccscene.primitive == 'CURVE_SEGMENTS': col.prop(ccscene, "subdivisions", text="Curve subdivisions") - row = col.row() - row.prop(ccscene, "minimum_width", text="Min Pixels") - row.prop(ccscene, "maximum_width", text="Max Extension") - class CYCLES_RENDER_PT_light_paths(CyclesButtonsPanel, Panel): bl_label = "Light Paths" @@ -270,6 +260,7 @@ class CYCLES_RENDER_PT_light_paths(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene cscene = scene.cycles @@ -279,31 +270,18 @@ class CYCLES_RENDER_PT_light_paths(CyclesButtonsPanel, Panel): row.operator("render.cycles_integrator_preset_add", text="", icon="ZOOMIN") row.operator("render.cycles_integrator_preset_add", text="", icon="ZOOMOUT").remove_active = True - split = layout.split() - - col = split.column() - - sub = col.column(align=True) - sub.label("Transparency:") - sub.prop(cscene, "transparent_max_bounces", text="Max") - - col.separator() + col = layout.column(align=True) + col.prop(cscene, "max_bounces", text="Max Bounces") + col.prop(cscene, "transparent_max_bounces", text="Transparency") + col.prop(cscene, "diffuse_bounces", text="Diffuse") + col.prop(cscene, "glossy_bounces", text="Glossy") + col.prop(cscene, "transmission_bounces", text="Transmission") + col.prop(cscene, "volume_bounces", text="Volume") + col = layout.column() + col.prop(cscene, "blur_glossy") col.prop(cscene, "caustics_reflective") col.prop(cscene, "caustics_refractive") - col.prop(cscene, "blur_glossy") - - col = split.column() - - sub = col.column(align=True) - sub.label(text="Bounces:") - sub.prop(cscene, "max_bounces", text="Max") - - sub = col.column(align=True) - sub.prop(cscene, "diffuse_bounces", text="Diffuse") - sub.prop(cscene, "glossy_bounces", text="Glossy") - sub.prop(cscene, "transmission_bounces", text="Transmission") - sub.prop(cscene, "volume_bounces", text="Volume") class CYCLES_RENDER_PT_motion_blur(CyclesButtonsPanel, Panel): @@ -317,6 +295,7 @@ class CYCLES_RENDER_PT_motion_blur(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene cscene = scene.cycles @@ -349,31 +328,35 @@ class CYCLES_RENDER_PT_motion_blur(CyclesButtonsPanel, Panel): class CYCLES_RENDER_PT_film(CyclesButtonsPanel, Panel): bl_label = "Film" + bl_options = {'DEFAULT_CLOSED'} def draw(self, context): layout = self.layout - + layout.use_property_split = True scene = context.scene cscene = scene.cycles - split = layout.split() - - col = split.column() + col = layout.column() col.prop(cscene, "film_exposure") - col.separator() - sub = col.column(align=True) - sub.prop(cscene, "pixel_filter_type", text="") + + layout.separator() + + col = layout.column() + col.prop(cscene, "pixel_filter_type") if cscene.pixel_filter_type != 'BOX': - sub.prop(cscene, "filter_width", text="Width") + col.prop(cscene, "filter_width") - col = split.column() + layout.separator() + + col = layout.column() col.prop(cscene, "film_transparent") - sub = col.row() + sub = col.column() sub.prop(cscene, "film_transparent_glass", text="Transparent Glass") sub.active = cscene.film_transparent - sub = col.row() - sub.prop(cscene, "film_transparent_roughness", text="Roughness Threshold") - sub.active = cscene.film_transparent and cscene.film_transparent_glass + + col = layout.column() + col.active = cscene.film_transparent and cscene.film_transparent_glass + col.prop(cscene, "film_transparent_roughness", text="Roughness Threshold") class CYCLES_RENDER_PT_performance(CyclesButtonsPanel, Panel): @@ -382,58 +365,58 @@ class CYCLES_RENDER_PT_performance(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene rd = scene.render cscene = scene.cycles - split = layout.split() - - col = split.column(align=True) + col = layout.column() - col.label(text="Threads:") - col.row(align=True).prop(rd, "threads_mode", expand=True) + col.row(align=True).prop(rd, "threads_mode") sub = col.column(align=True) sub.enabled = rd.threads_mode == 'FIXED' sub.prop(rd, "threads") col.separator() - sub = col.column(align=True) - sub.label(text="Tiles:") - sub.prop(cscene, "tile_order", text="") + col = layout.column() - sub.prop(rd, "tile_x", text="X") + sub = col.column(align=True) + sub.prop(rd, "tile_x", text="Tiles X") sub.prop(rd, "tile_y", text="Y") + col.prop(cscene, "tile_order", text="Order") - subsub = sub.column() - subsub.active = not rd.use_save_buffers + sub = col.column() + sub.active = not rd.use_save_buffers for view_layer in scene.view_layers: if view_layer.cycles.use_denoising: subsub.active = False - subsub.prop(cscene, "use_progressive_refine") + sub.prop(cscene, "use_progressive_refine") - col = split.column() + layout.separator() + + col = layout.column() - col.label(text="Final Render:") col.prop(rd, "use_save_buffers") col.prop(rd, "use_persistent_data", text="Persistent Images") - col.separator() + layout.separator() + + col = layout.column() - col.label(text="Acceleration structure:") col.prop(cscene, "debug_use_spatial_splits") col.prop(cscene, "debug_use_hair_bvh") - row = col.row() - row.active = not cscene.debug_use_spatial_splits - row.prop(cscene, "debug_bvh_time_steps") + sub = col.column() + sub.active = not cscene.debug_use_spatial_splits + sub.prop(cscene, "debug_bvh_time_steps") + + layout.separator() col = layout.column() - col.label(text="Viewport Resolution:") - split = col.split() - split.prop(rd, "preview_pixel_size", text="") - split.prop(cscene, "preview_start_resolution") + col.prop(rd, "preview_pixel_size", text="Viewport Pixel Size") + col.prop(cscene, "preview_start_resolution", text="Start Pixels") class CYCLES_RENDER_PT_filter(CyclesButtonsPanel, Panel): @@ -554,6 +537,7 @@ class CYCLES_RENDER_PT_denoising(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene cscene = scene.cycles @@ -562,43 +546,66 @@ class CYCLES_RENDER_PT_denoising(CyclesButtonsPanel, Panel): layout.active = cycles_view_layer.use_denoising - split = layout.split() - - col = split.column() - sub = col.column(align=True) + col = layout.column() + sub = col.column() sub.prop(cycles_view_layer, "denoising_radius", text="Radius") sub.prop(cycles_view_layer, "denoising_strength", slider=True, text="Strength") - col = split.column() sub = col.column(align=True) sub.prop(cycles_view_layer, "denoising_feature_strength", slider=True, text="Feature Strength") sub.prop(cycles_view_layer, "denoising_relative_pca") +# layout.use_property_split = False + + """ layout.separator() - row = layout.row() - row.label(text="Diffuse:") - sub = row.row(align=True) - sub.prop(cycles_view_layer, "denoising_diffuse_direct", text="Direct", toggle=True) - sub.prop(cycles_view_layer, "denoising_diffuse_indirect", text="Indirect", toggle=True) + col = layout.column(align=True) + col.prop(cycles_view_layer, "denoising_diffuse_direct", text="Diffuse Direct") + col.prop(cycles_view_layer, "denoising_diffuse_indirect", text="Indirect") - row = layout.row() - row.label(text="Glossy:") - sub = row.row(align=True) - sub.prop(cycles_view_layer, "denoising_glossy_direct", text="Direct", toggle=True) - sub.prop(cycles_view_layer, "denoising_glossy_indirect", text="Indirect", toggle=True) + col = layout.column(align=True) + col.prop(cycles_view_layer, "denoising_glossy_direct", text="Glossy Direct") + col.prop(cycles_view_layer, "denoising_glossy_indirect", text="Indirect") - row = layout.row() - row.label(text="Transmission:") - sub = row.row(align=True) - sub.prop(cycles_view_layer, "denoising_transmission_direct", text="Direct", toggle=True) - sub.prop(cycles_view_layer, "denoising_transmission_indirect", text="Indirect", toggle=True) + col = layout.column(align=True) + col.prop(cycles_view_layer, "denoising_transmission_direct", text="Transmission Direct") + col.prop(cycles_view_layer, "denoising_transmission_indirect", text="Indirect") - row = layout.row() - row.label(text="Subsurface:") - sub = row.row(align=True) - sub.prop(cycles_view_layer, "denoising_subsurface_direct", text="Direct", toggle=True) - sub.prop(cycles_view_layer, "denoising_subsurface_indirect", text="Indirect", toggle=True) + col = layout.column(align=True) + col.prop(cycles_view_layer, "denoising_subsurface_direct", text="Subsurface Direct") + col.prop(cycles_view_layer, "denoising_subsurface_indirect", text="Indirect") + """ + + layout.use_property_split = False + + split = layout.split(percentage=0.5) + split.label(text="Diffuse") + col = split.column() + row = col.row(align=True) + row.prop(cycles_view_layer, "denoising_diffuse_direct", text="Direct", toggle=True) + row.prop(cycles_view_layer, "denoising_diffuse_indirect", text="Indirect", toggle=True) + + split = layout.split(percentage=0.5) + split.label(text="Glossy") + col = split.column() + row = col.row(align=True) + row.prop(cycles_view_layer, "denoising_glossy_direct", text="Direct", toggle=True) + row.prop(cycles_view_layer, "denoising_glossy_indirect", text="Indirect", toggle=True) + + split = layout.split(percentage=0.5) + split.label(text="Transmission") + col = split.column() + row = col.row(align=True) + row.prop(cycles_view_layer, "denoising_transmission_direct", text="Direct", toggle=True) + row.prop(cycles_view_layer, "denoising_transmission_indirect", text="Indirect", toggle=True) + + split = layout.split(percentage=0.5) + split.label(text="Subsurface") + col = split.column() + row = col.row(align=True) + row.prop(cycles_view_layer, "denoising_subsurface_direct", text="Direct", toggle=True) + row.prop(cycles_view_layer, "denoising_subsurface_indirect", text="Indirect", toggle=True) class CYCLES_PT_post_processing(CyclesButtonsPanel, Panel): @@ -607,17 +614,15 @@ class CYCLES_PT_post_processing(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True rd = context.scene.render - split = layout.split() - - col = split.column() + col = layout.column(align=True) col.prop(rd, "use_compositing") col.prop(rd, "use_sequencer") - col = split.column() - col.prop(rd, "dither_intensity", text="Dither", slider=True) + layout.prop(rd, "dither_intensity", text="Dither", slider=True) class CYCLES_CAMERA_PT_dof(CyclesButtonsPanel, Panel): @@ -874,10 +879,14 @@ class CYCLES_LAMP_PT_preview(CyclesButtonsPanel, Panel): @classmethod def poll(cls, context): - return context.lamp and \ - not (context.lamp.type == 'AREA' and - context.lamp.cycles.is_portal) \ - and CyclesButtonsPanel.poll(context) + return ( + context.lamp and + not ( + context.lamp.type == 'AREA' and + context.lamp.cycles.is_portal + ) and + CyclesButtonsPanel.poll(context) + ) def draw(self, context): self.layout.template_preview(context.lamp) @@ -945,7 +954,7 @@ class CYCLES_LAMP_PT_nodes(CyclesButtonsPanel, Panel): def poll(cls, context): return context.lamp and not (context.lamp.type == 'AREA' and context.lamp.cycles.is_portal) and \ - CyclesButtonsPanel.poll(context) + CyclesButtonsPanel.poll(context) def draw(self, context): layout = self.layout @@ -1277,31 +1286,27 @@ class CYCLES_RENDER_PT_bake(CyclesButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene cscene = scene.cycles cbk = scene.render.bake rd = scene.render - if rd.use_bake_multires: - layout.operator("object.bake_image", icon='RENDER_STILL') - else: - layout.operator("object.bake", icon='RENDER_STILL').type = cscene.bake_type - col = layout.column() col.prop(rd, "use_bake_multires") if rd.use_bake_multires: col.prop(rd, "bake_type") - split = layout.split() - - col = split.column() + col = layout.column() col.prop(rd, "bake_margin") col.prop(rd, "use_bake_clear") - col = split.column() if rd.bake_type == 'DISPLACEMENT': col.prop(rd, "use_bake_lores_mesh") + + col.operator("object.bake_image", icon='RENDER_STILL') + else: col.prop(cscene, "bake_type") @@ -1310,26 +1315,22 @@ class CYCLES_RENDER_PT_bake(CyclesButtonsPanel, Panel): 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="") + sub = col.row(align=True) + sub.prop(cbk, "normal_r", text="Swizzle R") + sub.prop(cbk, "normal_g", text="G") + sub.prop(cbk, "normal_b", text="B") elif cscene.bake_type == 'COMBINED': row = col.row(align=True) + row.use_property_split = False 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 = col.column() + col.active = cbk.use_pass_direct or cbk.use_pass_indirect 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") @@ -1342,13 +1343,12 @@ class CYCLES_RENDER_PT_bake(CyclesButtonsPanel, Panel): layout.separator() - split = layout.split() - - col = split.column() + col = layout.column() col.prop(cbk, "margin") - col.prop(cbk, "use_clear") + col.prop(cbk, "use_clear", text="Clear Image") + + col.separator() - col = split.column() col.prop(cbk, "use_selected_to_active") sub = col.column() sub.active = cbk.use_selected_to_active @@ -1359,6 +1359,10 @@ class CYCLES_RENDER_PT_bake(CyclesButtonsPanel, Panel): else: sub.prop(cbk, "cage_extrusion", text="Ray Distance") + if rd.use_bake_multires == False: + layout.operator("object.bake", icon='RENDER_STILL').type = cscene.bake_type + + class CYCLES_RENDER_PT_debug(CyclesButtonsPanel, Panel): bl_label = "Debug" bl_context = "render" @@ -1434,7 +1438,6 @@ class CYCLES_SCENE_PT_simplify(CyclesButtonsPanel, Panel): row.prop(rd, "simplify_subdivision", text="Viewport") row.prop(rd, "simplify_subdivision_render", text="Render") - col = layout.column(align=True) col.label(text="Child Particles") row = col.row(align=True) @@ -1470,23 +1473,22 @@ class CYCLES_SCENE_PT_simplify(CyclesButtonsPanel, Panel): col = split.column() col.prop(cscene, "ao_bounces_render") + def draw_device(self, context): scene = context.scene layout = self.layout + layout.use_property_split = True if context.engine == 'CYCLES': from . import engine cscene = scene.cycles - split = layout.split(percentage=1 / 3) - split.label("Feature Set:") - split.prop(cscene, "feature_set", text="") + col = layout.column() + col.prop(cscene, "feature_set") - split = layout.split(percentage=1 / 3) - split.label("Device:") - row = split.row() - row.active = show_device_active(context) - row.prop(cscene, "device", text="") + col = layout.column() + col.active = show_device_active(context) + col.prop(cscene, "device") if engine.with_osl() and use_cpu(context): layout.prop(cscene, "shading_system") @@ -1517,7 +1519,7 @@ def get_panels(): 'VIEWLAYER_PT_layer_passes', 'RENDER_PT_post_processing', 'SCENE_PT_simplify', - } + } panels = [] for panel in bpy.types.Panel.__subclasses__(): diff --git a/release/scripts/startup/bl_ui/properties_object.py b/release/scripts/startup/bl_ui/properties_object.py index f0526fc0271..54b647f5b66 100644 --- a/release/scripts/startup/bl_ui/properties_object.py +++ b/release/scripts/startup/bl_ui/properties_object.py @@ -48,25 +48,40 @@ class OBJECT_PT_transform(ObjectButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + col = layout.column() ob = context.object - row = layout.row() + sub = col.row(align=True) + sub.prop(ob, "location") + sub.prop(ob, "lock_location", text="") - row.column().prop(ob, "location") if ob.rotation_mode == 'QUATERNION': - row.column().prop(ob, "rotation_quaternion", text="Rotation") + sub = col.row(align=True) + sub.prop(ob, "rotation_quaternion", text="Rotation") + subsub = sub.column(align=True) + subsub.prop(ob, "lock_rotation_w", text="") + subsub.prop(ob, "lock_rotation", text="") elif ob.rotation_mode == 'AXIS_ANGLE': - #row.column().label(text="Rotation") + # row.column().label(text="Rotation") #row.column().prop(pchan, "rotation_angle", text="Angle") #row.column().prop(pchan, "rotation_axis", text="Axis") - row.column().prop(ob, "rotation_axis_angle", text="Rotation") + sub = col.row(align=True) + sub.prop(ob, "rotation_axis_angle", text="Rotation") + subsub = sub.column(align=True) + subsub.prop(ob, "lock_rotation_w", text="") + subsub.prop(ob, "lock_rotation", text="") else: - row.column().prop(ob, "rotation_euler", text="Rotation") + sub = col.row(align=True) + sub.prop(ob, "rotation_euler", text="Rotation") + sub.prop(ob, "lock_rotation", text="") - row.column().prop(ob, "scale") + sub = col.row(align=True) + sub.prop(ob, "scale") + sub.prop(ob, "lock_scale", text="") - layout.prop(ob, "rotation_mode") + col.prop(ob, "rotation_mode") class OBJECT_PT_delta_transform(ObjectButtonsPanel, Panel): @@ -75,102 +90,65 @@ class OBJECT_PT_delta_transform(ObjectButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True ob = context.object - row = layout.row() + col = layout.column() - row.column().prop(ob, "delta_location") + col.column().prop(ob, "delta_location") if ob.rotation_mode == 'QUATERNION': - row.column().prop(ob, "delta_rotation_quaternion", text="Rotation") + col.column().prop(ob, "delta_rotation_quaternion", text="Rotation") elif ob.rotation_mode == 'AXIS_ANGLE': - #row.column().label(text="Rotation") + # row.column().label(text="Rotation") #row.column().prop(pchan, "delta_rotation_angle", text="Angle") #row.column().prop(pchan, "delta_rotation_axis", text="Axis") #row.column().prop(ob, "delta_rotation_axis_angle", text="Rotation") - row.column().label(text="Not for Axis-Angle") + col.column().label(text="Not for Axis-Angle") else: - row.column().prop(ob, "delta_rotation_euler", text="Delta Rotation") - - row.column().prop(ob, "delta_scale") - - -class OBJECT_PT_transform_locks(ObjectButtonsPanel, Panel): - bl_label = "Transform Locks" - bl_options = {'DEFAULT_CLOSED'} - - def draw(self, context): - layout = self.layout - - ob = context.object - - split = layout.split(percentage=0.1) + col.column().prop(ob, "delta_rotation_euler", text="Delta Rotation") - col = split.column(align=True) - col.label(text="") - col.label(text="X:") - col.label(text="Y:") - col.label(text="Z:") - - split.column().prop(ob, "lock_location", text="Location") - split.column().prop(ob, "lock_rotation", text="Rotation") - split.column().prop(ob, "lock_scale", text="Scale") - - if ob.rotation_mode in {'QUATERNION', 'AXIS_ANGLE'}: - row = layout.row() - row.prop(ob, "lock_rotations_4d", text="Lock Rotation") - - sub = row.row() - sub.active = ob.lock_rotations_4d - sub.prop(ob, "lock_rotation_w", text="W") + col.column().prop(ob, "delta_scale") class OBJECT_PT_relations(ObjectButtonsPanel, Panel): bl_label = "Relations" + bl_options = {'DEFAULT_CLOSED'} def draw(self, context): layout = self.layout + layout.use_property_split = True ob = context.object - split = layout.split() - - col = split.column() - col.prop(ob, "pass_index") + col = layout.column() - col = split.column() - col.label(text="Parent:") - col.prop(ob, "parent", text="") + col.prop(ob, "parent") sub = col.column() - sub.prop(ob, "parent_type", text="") + sub.prop(ob, "parent_type") parent = ob.parent if parent and ob.parent_type == 'BONE' and parent.type == 'ARMATURE': - sub.prop_search(ob, "parent_bone", parent.data, "bones", text="") + sub.prop_search(ob, "parent_bone", parent.data, "bones") sub.active = (parent is not None) + col = col.column() + col.active = (ob.parent is not None) + col.prop(ob, "use_slow_parent") + sub = col.column() + sub.active = (ob.use_slow_parent) + sub.prop(ob, "slow_parent_offset", text="Offset") -class OBJECT_PT_relations_extras(ObjectButtonsPanel, Panel): - bl_label = "Relations Extras" - bl_options = {'DEFAULT_CLOSED'} - - def draw(self, context): - layout = self.layout - - ob = context.object + col.separator() - split = layout.split() + col = layout.column() - col = split.column() - col.label(text="Tracking Axes:") - col.prop(ob, "track_axis", text="Axis") + col.prop(ob, "track_axis", text="Tracking Axis") col.prop(ob, "up_axis", text="Up Axis") - col = split.column() - col.prop(ob, "use_slow_parent") - row = col.row() - row.active = ((ob.parent is not None) and (ob.use_slow_parent)) - row.prop(ob, "slow_parent_offset", text="Offset") + col.separator() + + col.prop(ob, "pass_index") class COLLECTION_MT_specials(Menu): @@ -222,9 +200,11 @@ class OBJECT_PT_collections(ObjectButtonsPanel, Panel): class OBJECT_PT_display(ObjectButtonsPanel, Panel): bl_label = "Display" + bl_options = {'DEFAULT_CLOSED'} def draw(self, context): layout = self.layout + layout.use_property_split = True obj = context.object obj_type = obj.type @@ -233,9 +213,7 @@ class OBJECT_PT_display(ObjectButtonsPanel, Panel): is_empty_image = (obj_type == 'EMPTY' and obj.empty_draw_type == 'IMAGE') is_dupli = (obj.dupli_type != 'NONE') - split = layout.split() - - col = split.column() + col = layout.column(align=True) col.prop(obj, "show_name", text="Name") col.prop(obj, "show_axis", text="Axis") # Makes no sense for cameras, armatures, etc.! @@ -245,48 +223,44 @@ class OBJECT_PT_display(ObjectButtonsPanel, Panel): if obj_type == 'MESH' or is_dupli: col.prop(obj, "show_all_edges") - col = split.column() - row = col.row() - row.prop(obj, "show_bounds", text="Bounds") - sub = row.row() - sub.active = obj.show_bounds - sub.prop(obj, "draw_bounds_type", text="") + col = layout.column() + col.prop(obj, "show_bounds", text="Bounds") + col = layout.column() + col.active = obj.show_bounds + col.prop(obj, "draw_bounds_type") + col = layout.column() if is_geometry: col.prop(obj, "show_texture_space", text="Texture Space") - col.prop(obj.display, "show_shadows") + col.prop(obj.display, "show_shadows", text="Shadow") col.prop(obj, "show_x_ray", text="X-Ray") - if obj_type == 'MESH' or is_empty_image: - col.prop(obj, "show_transparent", text="Transparency") +# if obj_type == 'MESH' or is_empty_image: + # col.prop(obj, "show_transparent", text="Transparency") - split = layout.split() - - col = split.column() + col = layout.column() if is_wire: # wire objects only use the max. draw type for duplis col.active = is_dupli - col.label(text="Maximum Dupli Draw Type:") - else: - col.label(text="Maximum Draw Type:") - col.prop(obj, "draw_type", text="") + col.prop( + obj, "draw_type", + text="Maximum Dupli Draw Type" if is_wire else "Maximum Dupli Draw Type", + ) - col = split.column() + col = layout.column() if is_geometry or is_empty_image: # Only useful with object having faces/materials... - col.label(text="Object Color:") - col.prop(obj, "color", text="") + col.prop(obj, "color") - col = layout.column() + col = layout.column(align=True) col.active = bool(is_dupli or obj.particle_systems) - col.label(text="Duplicator Visibility:") - row = col.row(align=True) - row.prop(obj, "show_duplicator_for_viewport", text="Viewport") - row.prop(obj, "show_duplicator_for_render", text="Render") + col.prop(obj, "show_duplicator_for_viewport") + col.prop(obj, "show_duplicator_for_render") class OBJECT_PT_duplication(ObjectButtonsPanel, Panel): bl_label = "Duplication" + bl_options = {'DEFAULT_CLOSED'} def draw(self, context): layout = self.layout @@ -295,14 +269,15 @@ class OBJECT_PT_duplication(ObjectButtonsPanel, Panel): layout.row().prop(ob, "dupli_type", expand=True) + layout.use_property_split = True + if ob.dupli_type == 'FRAMES': - split = layout.split() - col = split.column(align=True) + col = layout.column(align=True) col.prop(ob, "dupli_frames_start", text="Start") col.prop(ob, "dupli_frames_end", text="End") - col = split.column(align=True) + col = layout.column(align=True) col.prop(ob, "dupli_frames_on", text="On") col.prop(ob, "dupli_frames_off", text="Off") @@ -312,9 +287,9 @@ class OBJECT_PT_duplication(ObjectButtonsPanel, Panel): layout.prop(ob, "use_dupli_vertices_rotation", text="Rotation") elif ob.dupli_type == 'FACES': - row = layout.row() - row.prop(ob, "use_dupli_faces_scale", text="Scale") - sub = row.row() + col = layout.column() + col.prop(ob, "use_dupli_faces_scale", text="Scale") + sub = col.column() sub.active = ob.use_dupli_faces_scale sub.prop(ob, "dupli_faces_scale", text="Inherit Scale") @@ -370,9 +345,7 @@ classes = ( OBJECT_PT_context_object, OBJECT_PT_transform, OBJECT_PT_delta_transform, - OBJECT_PT_transform_locks, OBJECT_PT_relations, - OBJECT_PT_relations_extras, COLLECTION_MT_specials, OBJECT_PT_collections, OBJECT_PT_display, diff --git a/release/scripts/startup/bl_ui/properties_render.py b/release/scripts/startup/bl_ui/properties_render.py index 404e4c4500b..92608cfccb9 100644 --- a/release/scripts/startup/bl_ui/properties_render.py +++ b/release/scripts/startup/bl_ui/properties_render.py @@ -125,6 +125,7 @@ class RENDER_PT_dimensions(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene rd = scene.render @@ -134,41 +135,33 @@ class RENDER_PT_dimensions(RenderButtonsPanel, Panel): row.operator("render.preset_add", text="", icon='ZOOMIN') row.operator("render.preset_add", text="", icon='ZOOMOUT').remove_active = True - split = layout.split() - - col = split.column() - sub = col.column(align=True) - sub.label(text="Resolution:") - sub.prop(rd, "resolution_x", text="X") - sub.prop(rd, "resolution_y", text="Y") - sub.prop(rd, "resolution_percentage", text="") + col = layout.column(align=True) + col.prop(rd, "resolution_x", text="Resolution X") + col.prop(rd, "resolution_y", text="Y") + col.prop(rd, "resolution_percentage") - sub.label(text="Aspect Ratio:") - sub.prop(rd, "pixel_aspect_x", text="X") - sub.prop(rd, "pixel_aspect_y", text="Y") + col = layout.column(align=True) + col.prop(rd, "pixel_aspect_x", text="Aspect X") + col.prop(rd, "pixel_aspect_y", text="Y") - row = col.row() - row.prop(rd, "use_border", text="Border") - sub = row.row() + col = layout.column(align=True) + col.prop(rd, "use_border", text="Border") + sub = col.column(align=True) sub.active = rd.use_border sub.prop(rd, "use_crop_to_border", text="Crop") - col = split.column() - sub = col.column(align=True) - sub.label(text="Frame Range:") - sub.prop(scene, "frame_start") - sub.prop(scene, "frame_end") - sub.prop(scene, "frame_step") + col = layout.column(align=True) + col.prop(scene, "frame_start", text="Frame Range Start") + col.prop(scene, "frame_end", text="End") + col.prop(scene, "frame_step", text="Step") - sub.label(text="Frame Rate:") + col = layout.split(percentage=0.5) + col.label(text="Frame Rate") + self.draw_framerate(col, rd) - self.draw_framerate(sub, rd) - - subrow = sub.row(align=True) - subrow.label(text="Time Remapping:") - subrow = sub.row(align=True) - subrow.prop(rd, "frame_map_old", text="Old") - subrow.prop(rd, "frame_map_new", text="New") + col = layout.column(align=True) + col.prop(rd, "frame_map_old", text="Time Remapping Old") + col.prop(rd, "frame_map_new", text="New") class RENDER_PT_post_processing(RenderButtonsPanel, Panel): @@ -178,16 +171,15 @@ class RENDER_PT_post_processing(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True rd = context.scene.render - split = layout.split() - - col = split.column() + col = layout.column(align=True) col.prop(rd, "use_compositing") col.prop(rd, "use_sequencer") - split.prop(rd, "dither_intensity", text="Dither", slider=True) + col.prop(rd, "dither_intensity", text="Dither", slider=True) class RENDER_PT_stamp(RenderButtonsPanel, Panel): @@ -197,24 +189,13 @@ class RENDER_PT_stamp(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = False rd = context.scene.render - layout.prop(rd, "use_stamp") - col = layout.column() - col.active = rd.use_stamp - row = col.row() - row.prop(rd, "stamp_font_size", text="Font Size") - row.prop(rd, "use_stamp_labels", text="Draw Labels") - - row = col.row() - row.column().prop(rd, "stamp_foreground", slider=True) - row.column().prop(rd, "stamp_background", slider=True) - - layout.label("Enabled Metadata") split = layout.split() - col = split.column() + col = split.column(align=True) col.prop(rd, "use_stamp_time", text="Time") col.prop(rd, "use_stamp_date", text="Date") col.prop(rd, "use_stamp_render_time", text="RenderTime") @@ -222,7 +203,7 @@ class RENDER_PT_stamp(RenderButtonsPanel, Panel): col.prop(rd, "use_stamp_scene", text="Scene") col.prop(rd, "use_stamp_memory", text="Memory") - col = split.column() + col = split.column(align=True) col.prop(rd, "use_stamp_camera", text="Camera") col.prop(rd, "use_stamp_lens", text="Lens") col.prop(rd, "use_stamp_filename", text="Filename") @@ -230,14 +211,26 @@ class RENDER_PT_stamp(RenderButtonsPanel, Panel): col.prop(rd, "use_stamp_marker", text="Marker") col.prop(rd, "use_stamp_sequencer_strip", text="Seq. Strip") - row = layout.split(percentage=0.2) + if rd.use_sequencer: + col.prop(rd, "use_stamp_strip_meta", text="Sequence Strip") + + row = layout.split(percentage=0.3) row.prop(rd, "use_stamp_note", text="Note") sub = row.row() sub.active = rd.use_stamp_note sub.prop(rd, "stamp_note_text", text="") - if rd.use_sequencer: - layout.label("Sequencer:") - layout.prop(rd, "use_stamp_strip_meta") + + layout.use_property_split = True + + layout.separator() + + layout.prop(rd, "use_stamp", text="Burn Into Image") + col = layout.column() + col.active = rd.use_stamp + col.prop(rd, "stamp_font_size", text="Font Size") + col.prop(rd, "use_stamp_labels", text="Draw Labels") + col.column().prop(rd, "stamp_foreground", slider=True) + col.column().prop(rd, "stamp_background", slider=True) class RENDER_PT_output(RenderButtonsPanel, Panel): @@ -246,6 +239,7 @@ class RENDER_PT_output(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = False rd = context.scene.render image_settings = rd.image_settings @@ -253,17 +247,17 @@ class RENDER_PT_output(RenderButtonsPanel, Panel): layout.prop(rd, "filepath", text="") - split = layout.split() - - col = split.column() - col.active = not rd.is_movie_format - col.prop(rd, "use_overwrite") - col.prop(rd, "use_placeholder") + layout.use_property_split = True - col = split.column() + col = layout.column(align=True) + sub = col.column(align=True) + sub.active = not rd.is_movie_format + sub.prop(rd, "use_overwrite") + sub.prop(rd, "use_placeholder") col.prop(rd, "use_file_extension") col.prop(rd, "use_render_cache") + layout.use_property_split = False layout.template_image_settings(image_settings, color_management=False) if rd.use_multiview: layout.template_image_views(image_settings) @@ -447,6 +441,7 @@ class RENDER_PT_eevee_ambient_occlusion(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene props = scene.eevee @@ -475,6 +470,7 @@ class RENDER_PT_eevee_motion_blur(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene props = scene.eevee @@ -500,6 +496,7 @@ class RENDER_PT_eevee_depth_of_field(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene props = scene.eevee @@ -525,6 +522,8 @@ class RENDER_PT_eevee_bloom(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee @@ -554,20 +553,32 @@ class RENDER_PT_eevee_volumetric(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee layout.active = props.use_volumetric col = layout.column() - col.prop(props, "volumetric_start") - col.prop(props, "volumetric_end") + sub = col.column(align=True) + sub.prop(props, "volumetric_start") + sub.prop(props, "volumetric_end") col.prop(props, "volumetric_tile_size") + col.separator() col.prop(props, "volumetric_samples") - col.prop(props, "volumetric_sample_distribution") + sub.prop(props, "volumetric_sample_distribution") + col.separator() col.prop(props, "use_volumetric_lights") - col.prop(props, "volumetric_light_clamp") + + sub = col.column() + sub.active = props.use_volumetric_lights + sub.prop(props, "volumetric_light_clamp", text="Light Clamping") + col.separator() col.prop(props, "use_volumetric_shadows") - col.prop(props, "volumetric_shadow_samples") + sub = col.column() + sub.active = props.use_volumetric_shadows + sub.prop(props, "volumetric_shadow_samples", text="Shadow Samples") + col.separator() col.prop(props, "use_volumetric_colored_transmittance") @@ -587,9 +598,13 @@ class RENDER_PT_eevee_subsurface_scattering(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee + layout.active = props.use_sss + col = layout.column() col.prop(props, "sss_samples") col.prop(props, "sss_jitter_threshold") @@ -612,12 +627,14 @@ class RENDER_PT_eevee_screen_space_reflections(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee col = layout.column() col.active = props.use_ssr - col.prop(props, "use_ssr_refraction") + col.prop(props, "use_ssr_refraction", text="Refraction") col.prop(props, "use_ssr_halfres") col.prop(props, "ssr_quality") col.prop(props, "ssr_max_roughness") @@ -637,6 +654,8 @@ class RENDER_PT_eevee_shadows(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee @@ -658,6 +677,8 @@ class RENDER_PT_eevee_sampling(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee @@ -678,6 +699,8 @@ class RENDER_PT_eevee_indirect_lighting(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene props = scene.eevee @@ -698,15 +721,13 @@ class RENDER_PT_eevee_film(RenderButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True + scene = context.scene rd = scene.render - split = layout.split() - - col = split.column() + col = layout.column() col.prop(rd, "filter_size") - - col = split.column() col.prop(rd, "alpha_mode", text="Alpha") @@ -737,9 +758,9 @@ classes = ( RENDER_PT_context, RENDER_PT_dimensions, RENDER_PT_post_processing, - RENDER_PT_stamp, RENDER_PT_output, RENDER_PT_encoding, + RENDER_PT_stamp, RENDER_UL_renderviews, RENDER_PT_stereoscopy, RENDER_PT_hair, diff --git a/release/scripts/startup/bl_ui/properties_scene.py b/release/scripts/startup/bl_ui/properties_scene.py index 4f3b293faa3..23714584acd 100644 --- a/release/scripts/startup/bl_ui/properties_scene.py +++ b/release/scripts/startup/bl_ui/properties_scene.py @@ -19,10 +19,10 @@ # <pep8 compliant> import bpy from bpy.types import ( - Menu, - Panel, - UIList, - ) + Menu, + Panel, + UIList, +) from rna_prop_ui import PropertyPanel @@ -69,12 +69,12 @@ class SCENE_PT_scene(SceneButtonsPanel, Panel): def draw(self, context): layout = self.layout - + layout.use_property_split = True scene = context.scene layout.prop(scene, "camera") - layout.prop(scene, "background_set", text="Background") - layout.prop(scene, "active_clip", text="Active Clip") + layout.prop(scene, "background_set") + layout.prop(scene, "active_clip") class SCENE_PT_unit(SceneButtonsPanel, Panel): @@ -91,23 +91,18 @@ class SCENE_PT_unit(SceneButtonsPanel, Panel): row.operator("scene.units_length_preset_add", text="", icon='ZOOMIN') row.operator("scene.units_length_preset_add", text="", icon='ZOOMOUT').remove_active = True - layout.separator() + layout.use_property_split = True - split = layout.split(percentage=0.35) - split.label("Length:") - split.prop(unit, "system", text="") - split = layout.split(percentage=0.35) - split.label("Angle:") - split.prop(unit, "system_rotation", text="") + col = layout.column() + col.prop(unit, "system") + + col = layout.column() + col.prop(unit, "system_rotation") col = layout.column() col.enabled = unit.system != 'NONE' - split = col.split(percentage=0.35) - split.label("Unit Scale:") - split.prop(unit, "scale_length", text="") - split = col.split(percentage=0.35) - split.row() - split.prop(unit, "use_separate") + col.prop(unit, "scale_length") + col.prop(unit, "use_separate") class SceneKeyingSetsPanel: @@ -115,18 +110,19 @@ class SceneKeyingSetsPanel: @staticmethod def draw_keyframing_settings(context, layout, ks, ksp): SceneKeyingSetsPanel._draw_keyframing_setting( - context, layout, ks, ksp, "Needed", - "use_insertkey_override_needed", "use_insertkey_needed", - userpref_fallback="use_keyframe_insert_needed") - + context, layout, ks, ksp, "Needed", + "use_insertkey_override_needed", "use_insertkey_needed", + userpref_fallback="use_keyframe_insert_needed", + ) SceneKeyingSetsPanel._draw_keyframing_setting( - context, layout, ks, ksp, "Visual", - "use_insertkey_override_visual", "use_insertkey_visual", - userpref_fallback="use_visual_keying") - + context, layout, ks, ksp, "Visual", + "use_insertkey_override_visual", "use_insertkey_visual", + userpref_fallback="use_visual_keying", + ) SceneKeyingSetsPanel._draw_keyframing_setting( - context, layout, ks, ksp, "XYZ to RGB", - "use_insertkey_override_xyz_to_rgb", "use_insertkey_xyz_to_rgb") + context, layout, ks, ksp, "XYZ to RGB", + "use_insertkey_override_xyz_to_rgb", "use_insertkey_xyz_to_rgb", + ) @staticmethod def _draw_keyframing_setting(context, layout, ks, ksp, label, toggle_prop, prop, userpref_fallback=None): @@ -197,6 +193,7 @@ class SCENE_PT_keying_sets(SceneButtonsPanel, SceneKeyingSetsPanel, Panel): class SCENE_PT_keying_set_paths(SceneButtonsPanel, SceneKeyingSetsPanel, Panel): bl_label = "Active Keying Set" + bl_options = {'DEFAULT_CLOSED'} COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_CLAY', 'BLENDER_EEVEE'} @classmethod @@ -258,22 +255,21 @@ class SCENE_PT_color_management(SceneButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene col = layout.column() - col.label(text="Display:") col.prop(scene.display_settings, "display_device") - col = layout.column() col.separator() - col.label(text="Render:") - col.template_colormanaged_view_settings(scene, "view_settings") col = layout.column() + col.template_colormanaged_view_settings(scene, "view_settings") + col.separator() - col.label(text="Sequencer:") - col.prop(scene.sequencer_colorspace_settings, "name") + col = layout.column() + col.prop(scene.sequencer_colorspace_settings, "name", text="Sequencer Color Space") class SCENE_PT_audio(SceneButtonsPanel, Panel): @@ -283,27 +279,29 @@ class SCENE_PT_audio(SceneButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene rd = context.scene.render ffmpeg = rd.ffmpeg layout.prop(scene, "audio_volume") - layout.operator("sound.bake_animation") - split = layout.split() + col = layout.column() + col.prop(scene, "audio_distance_model") + + col.prop(ffmpeg, "audio_channels") + col.prop(ffmpeg, "audio_mixrate", text="Sample Rate") - col = split.column() - col.label("Distance Model:") - col.prop(scene, "audio_distance_model", text="") - sub = col.column(align=True) - sub.prop(scene, "audio_doppler_speed", text="Speed") - sub.prop(scene, "audio_doppler_factor", text="Doppler") + layout.separator() - col = split.column() - col.label("Format:") - col.prop(ffmpeg, "audio_channels", text="") - col.prop(ffmpeg, "audio_mixrate", text="Rate") + col = layout.column(align=True) + col.prop(scene, "audio_doppler_speed", text="Doppler Speed") + col.prop(scene, "audio_doppler_factor", text="Doppler Factor") + + layout.separator() + + layout.operator("sound.bake_animation") class SCENE_PT_physics(SceneButtonsPanel, Panel): @@ -315,16 +313,18 @@ class SCENE_PT_physics(SceneButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True scene = context.scene layout.active = scene.use_gravity - layout.prop(scene, "gravity", text="") + layout.prop(scene, "gravity") class SCENE_PT_rigid_body_world(SceneButtonsPanel, Panel): bl_label = "Rigid Body World" + bl_options = {'DEFAULT_CLOSED'} COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_EEVEE'} @classmethod @@ -403,6 +403,7 @@ class SCENE_PT_rigid_body_field_weights(SceneButtonsPanel, Panel): class SCENE_PT_simplify(SceneButtonsPanel, Panel): bl_label = "Simplify" + bl_options = {'DEFAULT_CLOSED'} COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_CLAY', 'BLENDER_EEVEE'} def draw_header(self, context): @@ -411,22 +412,21 @@ class SCENE_PT_simplify(SceneButtonsPanel, Panel): def draw(self, context): layout = self.layout + layout.use_property_split = True rd = context.scene.render layout.active = rd.use_simplify - split = layout.split() + col = layout.column() + col.prop(rd, "simplify_subdivision", text="Max Viewport Subdivision") + col.prop(rd, "simplify_child_particles", text="Max Child Particles") - col = split.column() - col.label(text="Viewport:") - col.prop(rd, "simplify_subdivision", text="Subdivision") - col.prop(rd, "simplify_child_particles", text="Child Particles") + col.separator() - col = split.column() - col.label(text="Render:") - col.prop(rd, "simplify_subdivision_render", text="Subdivision") - col.prop(rd, "simplify_child_particles_render", text="Child Particles") + col = layout.column() + col.prop(rd, "simplify_subdivision_render", text="Max Render Subdivision") + col.prop(rd, "simplify_child_particles_render", text="Max Child Particles") class SCENE_PT_viewport_display(SceneButtonsPanel, Panel): |