Merge branch 'master' into blender2.8
[blender.git] / intern / cycles / blender / addon / properties.py
index 1b95c36561626a2941348bb91c9ae1e8d33c3b3b..6774fdaec6427619c963337d04a979aeca97328c 100644 (file)
@@ -200,12 +200,6 @@ class CyclesRenderSettings(bpy.types.PropertyGroup):
                 description="Pause all viewport preview renders",
                 default=False,
                 )
-        cls.preview_active_layer = BoolProperty(
-                name="Preview Active Layer",
-                description="Preview active render layer in viewport",
-                default=False,
-                )
-
         cls.aa_samples = IntProperty(
                 name="AA Samples",
                 description="Number of antialiasing samples to render for each pixel",
@@ -1200,15 +1194,15 @@ class CyclesCurveRenderSettings(bpy.types.PropertyGroup):
 def update_render_passes(self, context):
     scene = context.scene
     rd = scene.render
-    rl = rd.layers.active
-    rl.update_render_passes()
+    view_layer = scene.view_layers.active
+    view_layer.update_render_passes()
 
 class CyclesRenderLayerSettings(bpy.types.PropertyGroup):
     @classmethod
     def register(cls):
-        bpy.types.SceneRenderLayer.cycles = PointerProperty(
-                name="Cycles SceneRenderLayer Settings",
-                description="Cycles SceneRenderLayer Settings",
+        bpy.types.ViewLayer.cycles = PointerProperty(
+                name="Cycles ViewLayer Settings",
+                description="Cycles ViewLayer Settings",
                 type=cls,
                 )
         cls.pass_debug_bvh_traversed_nodes = BoolProperty(
@@ -1332,7 +1326,7 @@ class CyclesRenderLayerSettings(bpy.types.PropertyGroup):
 
     @classmethod
     def unregister(cls):
-        del bpy.types.SceneRenderLayer.cycles
+        del bpy.types.ViewLayer.cycles
 
 
 class CyclesCurveSettings(bpy.types.PropertyGroup):