diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-07-04 18:28:39 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2019-07-04 19:16:36 +0300 |
commit | 2740bdfff9f38807301fb3ee4d6a4949d8d8bb20 (patch) | |
tree | 5d3179972efbe297329c6ad1c6167b18b480c7a4 | |
parent | eed19d9f456c5ae6416c4d62d75a009f3a34bcc7 (diff) |
Fix T66362, T66004: Cycles holdout should override indirect only
Now it works again like 2.7, rather than objects disappearing from camera
rays when both options are on.
-rw-r--r-- | intern/cycles/blender/blender_object.cpp | 3 | ||||
-rw-r--r-- | source/blender/editors/space_outliner/outliner_draw.c | 3 |
2 files changed, 4 insertions, 2 deletions
diff --git a/intern/cycles/blender/blender_object.cpp b/intern/cycles/blender/blender_object.cpp index 17a0dbb43e7..7ccf8226e5b 100644 --- a/intern/cycles/blender/blender_object.cpp +++ b/intern/cycles/blender/blender_object.cpp @@ -357,7 +357,8 @@ Object *BlenderSync::sync_object(BL::Depsgraph &b_depsgraph, #endif /* Clear camera visibility for indirect only objects. */ - bool use_indirect_only = b_parent.indirect_only_get(PointerRNA_NULL, b_view_layer); + bool use_indirect_only = !use_holdout && + b_parent.indirect_only_get(PointerRNA_NULL, b_view_layer); if (use_indirect_only) { visibility &= ~PATH_RAY_CAMERA; } diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c index 86f99555e12..768a375675e 100644 --- a/source/blender/editors/space_outliner/outliner_draw.c +++ b/source/blender/editors/space_outliner/outliner_draw.c @@ -1443,7 +1443,8 @@ static void outliner_draw_restrictbuts(uiBlock *block, layer_collection, (char *)"indirect_only"); UI_but_flag_enable(bt, UI_BUT_DRAG_LOCK); - if (!props_active.layer_collection_indirect_only) { + if (props_active.layer_collection_holdout || + !props_active.layer_collection_indirect_only) { UI_but_flag_enable(bt, UI_BUT_INACTIVE); } } |