Separated Whitted from Path Tracing. Added FreeImage dependecy.
This commit is contained in:
@@ -57,8 +57,8 @@ vec3 PathTracer::trace_ray(Ray & r, vector<Figure *> & v_figures, vector<Light *
|
||||
dir_spec_color += vis ? v_lights[l]->specular(n, r, t, _f->m_mat) : vec3(0.0f);
|
||||
}
|
||||
|
||||
// If enabled, calculate indirect lighting contribution.
|
||||
if (indirect_l && rec_level < MAX_RECURSION) {
|
||||
// Calculate indirect lighting contribution.
|
||||
if (rec_level < MAX_RECURSION) {
|
||||
r1 = random01();
|
||||
r2 = random01();
|
||||
sample = sample_hemisphere(r1, r2);
|
||||
|
||||
Reference in New Issue
Block a user