Hi there.
I have mesh with 2 polygons and one directonal light.
The problem is when face of the mesh parallel to the light direction, it becomes completely black.
I’d like such faces to be just slightly darker(not 100% black).
Is there way to set ambient lighting for directional light?
I tried to play with Environment options in Windows->Rendering->Lighting but it doesn’t seem to affect anything in the game view.
In the lighting settings you should go to the environment settings and here you can change ambient light to color or gradient.
In newer unity versions you still need to build it in the bottom right of the window
I noticed environment settings work ok for default Lit material. Looks like you have to account ambient light manualy in custom URP shader graph.
That’s weird as my material defenetely receives some light from the light source, just without ambient component.
Looks like you created a sprite Lit shader graph, and then changed to Lit.
I think it’s because the sprite shader graph automatically disables some URP shader keywords, so you may find it strange that there’s no ambient light with the same shader graph settings.
Easiest solution: you can select + copy all the properties & nodes (Ctrl + Click), then paste them into a new Lit shader graph.
The problem was in Ambient Occlusion parameter of the shader graph. I had it equal to 0. Setting it to 1 brings env. lighting back.
This one is confusing. I always thought ambient occlusion is just post-processing effect.