Cycles: ambient occlusion support, with AO factor and distance, and a render pass.
[blender.git] / intern / cycles / kernel / kernel_passes.h
index a1b3b0e9038bca992a5ba0b6fb03241f59ca1caf..44e06be8c1633df6644126aca45e920ec02cf958 100644 (file)
@@ -123,6 +123,8 @@ __device_inline void kernel_write_light_passes(KernelGlobals *kg, __global float
                kernel_write_pass_float3(buffer + kernel_data.film.pass_emission, sample, L->emission);
        if(flag & PASS_BACKGROUND)
                kernel_write_pass_float3(buffer + kernel_data.film.pass_background, sample, L->background);
+       if(flag & PASS_AO)
+               kernel_write_pass_float3(buffer + kernel_data.film.pass_ao, sample, L->ao);
 
        if(flag & PASS_DIFFUSE_COLOR)
                kernel_write_pass_float3(buffer + kernel_data.film.pass_diffuse_color, sample, L->color_diffuse);