diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-02-28 20:45:08 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-02-28 20:45:08 +0400 |
commit | 22abc63f676dc7681ee8f734cbc96a7279172d24 (patch) | |
tree | 8f945d2a9db54869802aa5eb24c975488c99edd1 /intern/cycles/render/integrator.cpp | |
parent | 6cb896ff0a7d24be3ff500585642ae5d61a5b788 (diff) |
Cycles: ambient occlusion support, with AO factor and distance, and a render pass.
http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/World#Ambient_Occlusion
http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Passes#Lighting_Passes
Diffstat (limited to 'intern/cycles/render/integrator.cpp')
-rw-r--r-- | intern/cycles/render/integrator.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/intern/cycles/render/integrator.cpp b/intern/cycles/render/integrator.cpp index 47059a0a009..ff2afc7119b 100644 --- a/intern/cycles/render/integrator.cpp +++ b/intern/cycles/render/integrator.cpp @@ -83,6 +83,9 @@ void Integrator::device_update(Device *device, DeviceScene *dscene) kintegrator->seed = hash_int(seed); kintegrator->layer_flag = layer_flag << PATH_RAY_LAYER_SHIFT; + kintegrator->use_ambient_occlusion = + ((dscene->data.film.pass_flag & PASS_AO) || dscene->data.background.ao_factor != 0.0f); + /* sobol directions table */ int dimensions = PRNG_BASE_NUM + (max_bounce + transparent_max_bounce + 2)*PRNG_BOUNCE_NUM; uint *directions = dscene->sobol_directions.resize(SOBOL_BITS*dimensions); |