diff options
author | Julian T <julian@jtle.dk> | 2021-02-08 14:32:11 +0100 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2021-02-08 14:32:11 +0100 |
commit | dbe5f54957ddc13549a6ce822da95170aa09a0c6 (patch) | |
tree | 7cc45f25dd75cb7893fd0af49ae5353e38c5e392 /src/trace/mod.rs | |
parent | 6df0417568ef6f315138d9c3fd707ac3241a6a30 (diff) |
Rename to pathtrace, started for of depth of field, choose closest intersect
Diffstat (limited to 'src/trace/mod.rs')
-rw-r--r-- | src/trace/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/trace/mod.rs b/src/trace/mod.rs index cf06246..6c2c9f3 100644 --- a/src/trace/mod.rs +++ b/src/trace/mod.rs @@ -30,8 +30,8 @@ impl NormTracer<'_> { impl Tracer for NormTracer<'_> { fn trace(&self, _: &mut dyn Sampler, ray: &Ray) -> Spectrum { // Trace ray, we dont care about material - if let Some((_, i)) = self.scn.intersect(ray) { - let norm = i.n * 0.5 + Vector3f::new(0.5); + if let Some(si) = self.scn.intersect(ray) { + let norm = si.i.n * 0.5 + Vector3f::new(0.5); return Spectrum::new_rgb(norm.x, norm.y, norm.z); } |