Lighting problem

Hi everyone!

I have a problem with the game I’m working on… The beginning of my level is a cave, which I successfully made quite dark with a post process volume (I have a light source and a skylight in my scene), and when coming out of the cave, you enter a desert with a bright lighting. No problem so far, maybe the transition is a bit rough, but that’s ok… But the thing is, if I turn around and look back at my cave, well it’s lit. Like completely lit. (see link )

Now, the thing is in real life, you could maybe see a bit less in the cave, but definitely not better. And that’s the problem… I’d like my cave to stay dark even when looking back at it from a lit place…

I’ve been searching a bit, but every “dark interiors/bright exteriors” thread ends up with a different solution…

Thanks for your time!

Do you have a reflection capture actor in the cave? Try placing one in there.

Hey, I don’t currently have on that is near the cave entrance… I’ll try placing one the sooner I can!

Hi again!

I’ve tried putting a reflection sphere on the entrance of the cave, but it didn’t change much… Actually made the entrance a bit brighter…

At first, I thought it was the auto exposure, but no. The auto exposure mostly slows down the process of getting the cave brighter when looked from the outside, but when disabled, the cave is bright the moment you step out…

Any other ideas?

That shouldn’t happen if you are using lightmass, but if you are using all movable dynamic lights especially the skylight then yes you will most likely run into this situation, The moving skylight does not have shadowing in real time it just uses the SSAO to fake it and naturally it wont make those dark areas for you especially with the AO since its just screen space and not accurate ambient shadow like offline renderers.

If you use the stationary skylight light with lightmass you should be fine. I would also check exposure settings, the default one should already work if you need to test it first. Finally make sure you don’t have any ambient reflective areas, and as suggested in the above comment make sure you place the reflective sphere inside the cave or adjust the position until you find that its working.

A good rule of thumb is to remove all textures and create a simple grey material first with specularity 0 and roughness 0.8, apply it on everything and check lighting, later increase specularity to 0.3 to 0.6 and check again.

Yesterday I found out that lowering the number of light bounces in the world settings reduced the lightning in the cave, from the entrance; now, the landscape in the cave stays dark, while the static meshes that make the walls are still too bright.

I’m using the stationary skylight… By using lightmass, you’re referring to using Importance Volumes? I’ll try the reflection sphere again, but last time it didn’t change much… How can I adjust the exposure settings though? That might come out handy…

I don’t understand why we don’t have “light blocking volumes” for example, that would be awesome…

Oh and while I’m at it, the strange thing is on of my other cave in the same level doesn’t have this problem… I mean, from outside the cave, facing the entrance, even when the auto exposure kicked in, it’s still dark inside… how could this be?

Seems like it’s a special case scenario,you should check those meshes and make sure you don’t have any normals issues or other mesh errors. Ligthtmass bounces shouldn’t make a drastic difference like that. Just make sure environment color in world settings is set to black.

You don’t need light blocking volumes since everything should work as is and lighting should look more or less correct. If you need to block a certain area with specific shadows you can use any object just set it not to dispaly in game but to only cast shadows. You can even use maps on the lights themselves.

The exposure settings is in post process volume under eye adaption or auto exposure. check docs.

Ok, will check all of your suggestions and report back! Thanks a lot

It seemed to be just like you were saying… The skylight “static/stationary/movable” solves the problem… but then my shadows are becoming WAY too dark, which is why I set the skylight to movable to begin with…

Just throw in some really dim point lights in lighten up the area. Eye adaptation should also compensate for the difference in brightness.

You mean like placing point lights everywhere there are shadows? Won’t that complicate the scene?

If you are doing it like i mentioned above, the shadows should be fine and not too dark (without movable skylight), eye adaptation in post process is the key in your case and should also help, but if you are concerned that the cave is still dark in some places even with eye adaptation, then you must think like you would in real life. Caves are dark so make a hole somewhere in the cave to justify light leak from outside, put extra spot lights directed at certain places etc. this is lighting and good lighting is a field on its own. I suggest you experiment with this and also look into photography to understand exposure.

Ok, well I’ll try again with the eye exposure and see… thanks =)