[Soc-2018-dev] Weekly Report #12 - Many Light Sampling

Brecht Van Lommel brechtvanlommel at gmail.com
Fri Aug 3 21:43:50 CEST 2018


Hi,

Great work fixing all those cases!

You're certainly allowed to work on the code next week or any other time.
There's just no obligation to do it from this point on.

For documentation, for this project I expect mostly code comments.

When we release this we'll also need end user documentation, which would be
a few sentences explaining what the new settings do. But there's not a lot
to explain here.

Regards,
Brecht.


On Fri, Aug 3, 2018, 19:43 Erik Englesson <erikenglesson at gmail.com> wrote:

> Hi all,
>
> *This week* I have been trying my branch on some of the demo scenes and
> found bugs that I have started to fix.
>
> In the Barcelona Pavillion scene, I noticed that instancing of mesh lights
> did not work. This was fixed in this commit
> <https://developer.blender.org/rB84fec2152261>. In the same commit, I
> also fixed the emission to luminance conversion to use linear_rgb_to_gray()
> instead of my own. I also noted that mesh lights are double sided which I
> have not had time to do anything about(considered single sided right now).
>
> When debugging the fishy cat scene that Brecht mentioned last week I found
> a bug in the energy calculations for each light source. If it did not have
> constant emission then I considered it to have no energy at all. This has
> now been changed so it uses an emission of (1,1,1) instead.
> The light picking method uses a diffuse approximation term in the
> importance metric which depends on the surface normal at the point. This
> normal used to make sure that only lights in the same hemisphere as the
> normal is pointing towards got sampled. However, this should not be the
> case for any surface where refraction is possible. This case came to light
> from the transparent cornea of the cat. Both the energy and the normal
> issues have been fixed here
> <https://developer.blender.org/rB108594d8c844edb09afdac1a355f0b6d99cb80db>
> .
>
> The classroom scene is a very complex test scene. The window is a mesh
> light and a portal that has a normal pointing out from the room, there is a
> strong fill light just outside pointing away from the room, the blackboard
> lamp consists of a mesh light(non-constant emission) and an area light in
> front of it, there is a strong point light in the corridor that is not
> visible for most points and finally a strong distant light.
> In this scene, I found that the bounding boxes I calculated for area
> lights were wrong. This was fixed here
> <https://developer.blender.org/rB5d344f43603ddba8f3a009915b92a5374066efeb>
> .
> There was a dustbin that was transparent which made me realize(with the
> help of Brecht) that the position and normal that is used for the light
> picking should be from the last non-transparent bounce. This change can be
> found here <https://developer.blender.org/rBe8e0669785cd>.
>
> Brecht mentioned that I use doubles in the split heuristic to avoid some
> precision and overflow issues but doubles will not work well for the GPU. I
> have now changed this to use floats instead but I am still using doubles to
> calculate the energy variance on the host which seems to be where the
> precision issues came from. The overflow problem was related to squaring
> the number of emitters in the node. When I saw that it overflowed I think I
> used integers to calculate the square which has a much lower maximum value
> than floats. It does not seem to overflow anymore at least. This change can
> be found here
> <https://developer.blender.org/rBf6305047f44bf3168b1da8601307d78015ad8f65>
> .
>
> I have also continued the work on volumes. I think I have been able to
> only use the new light picking strategy for shading points that are not
> inside or on the boundary of a volume. For volume points, it is using the
> old picking method. This is until the volume part of the paper has been
> implemented. I also fixed a bug in light_background_sample() that used an
> index into the lights array as an index into the distribution array. The
> volume changes and the bug fix can be found here
> <https://developer.blender.org/rB94af4326e3fc22fe1b229a3e2435fb6ccfe36ce9>
> .
>
> *Next week* is a bit unclear to me. Am I only supposed to write
> documentation and do the evaluation? If so, what kind of documentation do
> you want? There are still things I have not had time to fix, e.g. the clock
> in the classroom scene is darker using the light tree, branched vs normal
> path tracing has some brightness differences(I have not implemented
> splitting in light_bvh_pdf() ), doing something about mesh lights being
> double sided, add more comments to the code, splitting is not implemented
> for branched path tracing of volumes, add tests, try running on GPU, etc.
> Can I work on some of this next week? I would appreciate if someone could
> clarify this for me.
>
> Have a great weekend!
>
> Thanks,
> Erik
> --
> Soc-2018-dev mailing list
> Soc-2018-dev at blender.org
> https://lists.blender.org/mailman/listinfo/soc-2018-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.blender.org/pipermail/soc-2018-dev/attachments/20180803/b18f40ea/attachment-0001.html>


More information about the Soc-2018-dev mailing list