Merge branch 'master' into blender2.8
[blender.git] / intern / cycles / blender / addon / properties.py
index a63d84f2da68ba57723939d5c12235d77ea152a5..91119c5c71c534716afcaa5a1a3e04da782a5eba 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):