How to optimize window lighting?

CarbonBlue

Developer of Unleashed
Game Developer
Oct 25, 2018
1,119
7,691
Lighting is one of the weaker points in my renders. I'm improving it, and increasingly using lighting through windows. The problem is that it increases the render time significantly. For example, take this render I just did. I realize it's way too bright, btw. But this render took just a few minutes when I moved the spotlight inside the room. When it was outside the window of the room it wasn't even on 1% after 10 minutes. Is there a trick to improving the rendering speed with a spotlight outside a window?
ep3_24.png
 

Porcus Dev

Engaged Member
Game Developer
Oct 12, 2017
2,582
4,685
Daz finds it more difficult to calculate the light interaction if it passes through transparent or reflective surfaces.

I don't see the need to put the light outside of the window if it isn't visible.

I recommend that you try to put "emissive surfaces" ( or for example)to solve lighting problems ... I personally don't like very much the "spotlights" that has Daz by default.
 
  • Like
Reactions: CarbonBlue

recreation

pure evil!
Respected User
Game Developer
Jun 10, 2018
6,250
22,142
the problem is that glass-shader are reflective surfaces, so a light behind a window outside of the scene will reflect the outside + when the light hits the interior, it will reflect the inside, which then get's calculated again to reflect on the outside. It's a really complex process and hard to explain, but generally speaking, light coming from the outside through a window is way harder to process and therefore takes longer.
 
  • Like
Reactions: CarbonBlue

Rich

Old Fart
Modder
Respected User
Donor
Game Developer
Jun 25, 2017
2,452
6,900
Daz finds it more difficult to calculate the light interaction if it passes through transparent or reflective surfaces.
the problem is that glass-shader are reflective surfaces
Yes, that's certainly part of the problem. One thing that you can consider if the window does have to be visible in the render is to delete the glass surfaces using the Geometry Editor so that the window panes are completely empty, rather than actually having glass in them. Or, at least, select the glass surfaces and set their opacity and glossiness all the way to zero. That cuts down on calculations a bit.

The other part of the problem is that iRay treats lights specially. If there's nothing between the light and the object being lit, iRay can do the lighting calculations very, very simply. As soon as the light has to pass through anything, things get much more complex for iRay because of the possibility that the material its going through will cause caustics, etc. (This is essentially what mgomez0077 is saying.)

I don't see the need to put the light outside of the window if it isn't visible.
Completely true. We, as 3D renderers, get to ignore "reality" when it's convenient. Thus, you could easily move the spotlight just inside the window, set it to to be rectangular and the same dimensions as the window, and you'll have the illusion that light is coming through the window.

There is also one other thing you can try. If you look at the settings under Light > Area, there's one called "Light Portal" which defaults to "Off." If you create a spotlight just inside the window, align it to the window and set Light Portal to "On," what this is SUPPOSED to do is to tell iRay to pay special attention to this area of the scene because light will be coming from this area. In other words, this isn't a spotlight itself any more, but a hint as to where light is coming from. I fiddled with this some years ago and had mixed results with it in terms of reducing render times. In general, I moved on to other techniques, such as the ones mgomez0077 mentioned with ghost lights, etc., but it's at least something you might want to experiment with as well.
 

mickydoo

Fudged it again.
Game Developer
Jan 5, 2018
2,446
3,545
I take the glass out of them like Rich suggested, its easy to fudge glass in photoshop, and either put an emission pane where the window is or ideally try and get a HDRI to shine through it. I have sourced a couple that are good for that, though it doesn't always work.
 

CarbonBlue

Developer of Unleashed
Game Developer
Oct 25, 2018
1,119
7,691
I don't see the need to put the light outside of the window if it isn't visible.
The shadows cast by the window panes and blinds can be pretty cool. But I think I'll save those for special renders and just bring the lights inside most of the time.
 

Saki_Sliz

Well-Known Member
May 3, 2018
1,403
992
What happens when you try to have light come through the window to illuminate a room is that you are now lighting it indirectly. This tends to make the light softer, but also relies on light bounces to illuminate the rooms. light bounce is what makes raytracing hard. To have light better get into a room when lighting a room with inderectl light such as through the window, you need more light mounces to allow more light to get in, but this comes at the risk of generating a noisier image. In the movie big hero 6, the artist needed 12 bounces to get the style they wanted, where rooms glowed ambient colors, most of the time 3 bounces is standard. to deal with the noise, you need more samples to help clean up the image, and hense more time rendering. a fix for this is emulate the effect of lighting a room with a window with just a lamp. nothing new, but what people don't realize is that the light must also be soft to properly replicate how light is soft when it is viewed indirectly like through a window, to make light soft you just simulate the light being larger, such as with an area light that fills up a window, or you can project a texture through the window and use it as a light texture. Not sure how to do this in daz, as I port everything to blender.
 
  • Like
Reactions: CarbonBlue