Page 1 of 1

How to deal with mesh emitters?

Posted: Sun Dec 25, 2011 1:29 am
by khalidsalman
Hi,

So regarding mesh emitters, should I treat them as mesh or as emitters?

since they are intersectable meshes, they can be randomely hit with traced rays, however that would signifantly reduce convergce speed of direct lighting. They can also be treated as regular lights which get sampled and connected to the current path vertex, but the problem is that with emitter meshes consisting of tens of thousands of triangles, sampling few of them would not help at all (at least that's what I think)

so to give a concreate example, imagine the following situation: you have a scene with few delta lights, and few mesh emitters with thousands of triangles each, what is a good sampling strategy? is it good enough to sample delta lights and depend on regular intersection for emitters? or what else?

Hope my question is clear.

And thanks for your help..

Re: How to deal with mesh emitters?

Posted: Mon Dec 26, 2011 8:57 pm
by ingenious
The answer is both. That is, you should sample them explicitly and allow intersection by random rays. The reason is, as you have figured out yourself, that depending on the situation, one strategy might be better than the other. The contributions from the two strategies must be combined with multiple importance sampling (MIS). As for the complexity - it doesn't really matter whether a light source is represented by 2 or 1000 triangles, if you think about it.

Re: How to deal with mesh emitters?

Posted: Tue Dec 27, 2011 12:21 am
by tstanev
If the visual angle covered by the light sources is on average very small (regardless of number of triangles), you are probably better off sampling them explicitly (using importance sampling), in order to avoid noise. Another option may be to approximate each mesh emitter by a series of point lights, then sample them together with your other point lights. The best solution probably depends on what exactly your scene (and your goal) is, but for the general solution is what ingenious said (multiple importance sampling).

Re: How to deal with mesh emitters?

Posted: Tue Dec 27, 2011 9:29 am
by ingenious
tstanev wrote:If the visual angle covered by the light sources is on average very small (regardless of number of triangles), you are probably better off sampling them explicitly (using importance sampling), in order to avoid noise. Another option may be to approximate each mesh emitter by a series of point lights, then sample them together with your other point lights. The best solution probably depends on what exactly your scene (and your goal) is, but for the general solution is what ingenious said (multiple importance sampling).
In my experience, combining the contributions with MIS deals with the variance problem perfectly. I've had my doubts about MIS before [here a link to the old Ompf thread would go], but I strongly argue that there's probably no other more elegant and practical solution than MIS for this case. As someone said before, just add MIS and forget about it.