diff options
author | Jeroen Bakker <j.bakker@atmind.nl> | 2018-06-06 15:47:54 +0300 |
---|---|---|
committer | Jeroen Bakker <j.bakker@atmind.nl> | 2018-06-06 15:51:18 +0300 |
commit | f1fd5ed74fb0afd602f53860d0b2db46189c218a (patch) | |
tree | 47af0711292c8dcf5e157473b21949c706540b75 /release/scripts/startup | |
parent | 4a52531a11fa27da36f9dbe849ecf0573f35a47b (diff) |
T55333 Workbench: Cavity Shader
A cavity shader based on SSAO. Works on all workbench deferred passes.
Per 3d viewport the cavity shader options can be set as different
shading needed different options. Some global options are in the
Viewport Display of the scene like num samples and distance.
Experimental: Naming of Ridges and Valleys
Diffstat (limited to 'release/scripts/startup')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_scene.py | 19 | ||||
-rw-r--r-- | release/scripts/startup/bl_ui/space_view3d.py | 8 |
2 files changed, 27 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_ui/properties_scene.py b/release/scripts/startup/bl_ui/properties_scene.py index 1b9c7b5eacb..33e89014538 100644 --- a/release/scripts/startup/bl_ui/properties_scene.py +++ b/release/scripts/startup/bl_ui/properties_scene.py @@ -476,6 +476,24 @@ class SCENE_PT_viewport_display(SceneButtonsPanel, Panel): col.prop(scene.display, "shadow_shift") +class SCENE_PT_viewport_display_ssao(SceneButtonsPanel, Panel): + bl_label = "Viewport Display SSAO" + bl_parent_id = "SCENE_PT_viewport_display" + + @classmethod + def poll(cls, context): + return True + + def draw(self, context): + layout = self.layout + layout.use_property_split = True + scene = context.scene + col = layout.column() + col.prop(scene.display, "matcap_ssao_samples") + col.prop(scene.display, "matcap_ssao_distance") + col.prop(scene.display, "matcap_ssao_attenuation") + + class SCENE_PT_custom_props(SceneButtonsPanel, PropertyPanel, Panel): COMPAT_ENGINES = {'BLENDER_RENDER', 'BLENDER_CLAY', 'BLENDER_EEVEE'} _context_path = "scene" @@ -492,6 +510,7 @@ classes = ( SCENE_PT_color_management, SCENE_PT_color_management_curves, SCENE_PT_viewport_display, + SCENE_PT_viewport_display_ssao, SCENE_PT_audio, SCENE_PT_physics, SCENE_PT_rigid_body_world, diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py index 1a70092eb21..149f93245df 100644 --- a/release/scripts/startup/bl_ui/space_view3d.py +++ b/release/scripts/startup/bl_ui/space_view3d.py @@ -3528,6 +3528,14 @@ class VIEW3D_PT_shading(Panel): sub.prop(shading, "shadow_intensity", text="") row = col.row() + row.active = not shading.show_xray + row.prop(shading, "show_cavity") + sub = row.column() + sub.active = not shading.show_xray and shading.show_cavity + sub.prop(shading, "cavity_ridge_factor") + sub.prop(shading, "cavity_valley_factor") + + row = col.row() row.prop(shading, "show_object_outline") sub = row.row() sub.active = shading.show_object_outline |