Merge branch 'master' into blender2.8
authorTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>
Thu, 8 Feb 2018 18:00:20 +0000 (03:00 +0900)
committerTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>
Thu, 8 Feb 2018 18:00:20 +0000 (03:00 +0900)
Conflicts:
intern/cycles/blender/addon/ui.py

1  2 
intern/cycles/blender/addon/ui.py
tests/python/CMakeLists.txt

index 13bb00949824509464932dadbdd606d3570de94c,e3076a8ec2ce4b0ebcdc5b8a832f1a85d3b44e49..d5f72654c723ccbc7476a3a24f935f90c9a23534
@@@ -442,15 -449,39 +442,21 @@@ class CYCLES_RENDER_PT_layer_options(Cy
  
      def draw(self, context):
          layout = self.layout
+         with_freestyle = bpy.app.build_options.freestyle
  
          scene = context.scene
 -        rl = rd.layers.active
 -
 -        split = layout.split()
 -
 -        col = split.column()
 -        col.prop(scene, "layers", text="Scene")
 -        col.prop(rl, "layers_exclude", text="Exclude")
 -
 -        col = split.column()
 -        col.prop(rl, "layers", text="Layer")
 -        col.prop(rl, "layers_zmask", text="Mask Layer")
+         rd = scene.render
 +        view_layer = scene.view_layers.active
  
 -        split = layout.split()
 -
 -        col = split.column()
 -        col.label(text="Material:")
 -        col.prop(rl, "material_override", text="")
 -        col.separator()
 -        col.prop(rl, "samples")
 -
 -        col = split.column()
 -        col.prop(rl, "use_sky", "Use Environment")
 -        col.prop(rl, "use_ao", "Use AO")
 -        col.prop(rl, "use_solid", "Use Surfaces")
 -        col.prop(rl, "use_strand", "Use Hair")
 +        col = layout.column()
 +        col.prop(view_layer, "use_sky", "Use Environment")
 +        col.prop(view_layer, "use_ao", "Use AO")
 +        col.prop(view_layer, "use_solid", "Use Surfaces")
 +        col.prop(view_layer, "use_strand", "Use Hair")
+         if with_freestyle:
+             row = col.row()
 -            row.prop(rl, "use_freestyle", "Use Freestyle")
++            row.prop(view_layer, "use_freestyle", "Use Freestyle")
+             row.active = rd.use_freestyle
  
  
  class CYCLES_RENDER_PT_layer_passes(CyclesButtonsPanel, Panel):
Simple merge